mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-11-11 05:11:49 +01:00
Remove redundant built-in routine lookups
Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
03ab5e07c3
commit
940df6a77c
1 file changed
-2
@@ -237,7 +237,6 @@ export function builtInAgentRoutes(db: Db) {
|
||||
const routineKey = req.params.routineKey as string;
|
||||
await assertBuiltInAgentsEnabled();
|
||||
assertCompanyAccess(req, companyId);
|
||||
const current = await svc.get(companyId, key);
|
||||
await assertCanControlBuiltInRoutine(req, companyId);
|
||||
const actor = getActorInfo(req);
|
||||
const state = await svc.enableRoutineSchedule(companyId, key, routineKey, {
|
||||
@@ -266,7 +265,6 @@ export function builtInAgentRoutes(db: Db) {
|
||||
const routineKey = req.params.routineKey as string;
|
||||
await assertBuiltInAgentsEnabled();
|
||||
assertCompanyAccess(req, companyId);
|
||||
const current = await svc.get(companyId, key);
|
||||
await assertCanControlBuiltInRoutine(req, companyId);
|
||||
const actor = getActorInfo(req);
|
||||
const state = await svc.disableRoutineSchedule(companyId, key, routineKey, {
|
||||
|
||||
Reference in new issue
Block a user