diff --git a/src/settings.js b/src/settings.js index 4ca47e3f6..b315df61c 100644 --- a/src/settings.js +++ b/src/settings.js @@ -499,7 +499,7 @@ function setExternalLdapConfig(externalLdapConfig, callback) { assert.strictEqual(typeof externalLdapConfig, 'object'); assert.strictEqual(typeof callback, 'function'); - if (settings.isDemo()) return callback(new BoxError(BoxError.BAD_FIELD, 'Not allowed in demo mode')); + if (isDemo()) return callback(new BoxError(BoxError.BAD_FIELD, 'Not allowed in demo mode')); getExternalLdapConfig(function (error, currentConfig) { if (error) return callback(error); @@ -599,7 +599,7 @@ function setDirectoryConfig(directoryConfig, callback) { assert.strictEqual(typeof directoryConfig, 'object'); assert.strictEqual(typeof callback, 'function'); - if (settings.isDemo()) return callback(new BoxError(BoxError.BAD_FIELD, 'Not allowed in demo mode')); + if (isDemo()) return callback(new BoxError(BoxError.BAD_FIELD, 'Not allowed in demo mode')); settingsdb.set(exports.DIRECTORY_CONFIG_KEY, JSON.stringify(directoryConfig), function (error) { if (error) return callback(error);