diff --git a/core/boot.js b/core/boot.js index a490e62a7b..ff2cbb9d52 100644 --- a/core/boot.js +++ b/core/boot.js @@ -219,6 +219,10 @@ async function initServices({config}) { async function initBackgroundServices({config}) { debug('Begin: initBackgroundServices'); + // Load all inactive themes + const themeService = require('./server/services/themes'); + themeService.loadInactiveThemes(); + // we don't want to kick off background services that will interfere with tests if (process.env.NODE_ENV.match(/^testing/)) { return; @@ -230,10 +234,6 @@ async function initBackgroundServices({config}) { await emailAnalyticsJobs.scheduleRecurringJobs(); } - // Load all inactive themes - const themeService = require('./server/services/themes'); - themeService.loadInactiveThemes(); - const updateCheck = require('./server/update-check'); updateCheck.scheduleRecurringJobs(); diff --git a/test/utils/acceptance-utils.js b/test/utils/acceptance-utils.js index 638270f139..f0630c5be5 100644 --- a/test/utils/acceptance-utils.js +++ b/test/utils/acceptance-utils.js @@ -118,9 +118,6 @@ const restartModeGhostStart = async () => { // @TODO: why does this happen _after_ URL service web.shared.middlewares.customRedirects.reload(); - // Trigger themes to load again - themeService.loadInactiveThemes(); - // Reload limits service limits.init(); };