From 10699edd3bb8f08810a2075f97fdcb93b50b0729 Mon Sep 17 00:00:00 2001 From: Rory Powell Date: Mon, 21 Mar 2022 16:08:25 +0000 Subject: [PATCH] Remove automation usage increment --- packages/server/src/threads/automation.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/packages/server/src/threads/automation.js b/packages/server/src/threads/automation.js index c0843a286c..f1df5c3dab 100644 --- a/packages/server/src/threads/automation.js +++ b/packages/server/src/threads/automation.js @@ -1,13 +1,11 @@ require("./utils").threadSetup() -const env = require("../environment") const actions = require("../automations/actions") const automationUtils = require("../automations/automationUtils") const AutomationEmitter = require("../events/AutomationEmitter") const { processObject } = require("@budibase/string-templates") const { DEFAULT_TENANT_ID } = require("@budibase/backend-core/constants") -const { DocumentTypes, isDevAppID } = require("../db/utils") +const { DocumentTypes } = require("../db/utils") const { doInTenant } = require("@budibase/backend-core/tenancy") -const usage = require("../utilities/usageQuota") const { definitions: triggerDefs } = require("../automations/triggerInfo") const { doInAppContext, getAppDB } = require("@budibase/backend-core/context") @@ -120,11 +118,6 @@ class Orchestrator { return err } } - - // Increment quota for automation runs - if (!env.SELF_HOSTED && !isDevAppID(this._appId)) { - await usage.update(usage.Properties.AUTOMATION, 1) - } return this.executionOutput } }