From 01b72b6b71fbce85fd79f2079f9d9cfd530a2b9e Mon Sep 17 00:00:00 2001 From: mike12345567 Date: Wed, 15 Dec 2021 12:26:29 +0000 Subject: [PATCH] Don't run change if not threading. --- packages/server/src/threads/utils.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/server/src/threads/utils.js b/packages/server/src/threads/utils.js index 13e9daf711..48b40d7002 100644 --- a/packages/server/src/threads/utils.js +++ b/packages/server/src/threads/utils.js @@ -3,6 +3,10 @@ const CouchDB = require("../db") const { init } = require("@budibase/auth") exports.threadSetup = () => { + // don't run this if not threading + if (env.isTest() || env.DISABLE_THREADING) { + return + } // when thread starts, make sure it is recorded env.setInThread() init(CouchDB)