diff --git a/packages/node_modules/@node-red/runtime/lib/nodes/context/localfilesystem.js b/packages/node_modules/@node-red/runtime/lib/nodes/context/localfilesystem.js index 0f83573e8..cf1769700 100644 --- a/packages/node_modules/@node-red/runtime/lib/nodes/context/localfilesystem.js +++ b/packages/node_modules/@node-red/runtime/lib/nodes/context/localfilesystem.js @@ -245,7 +245,7 @@ LocalFileSystem.prototype.get = function(scope, key, callback) { return this.cache.get(scope,key,callback); } if(typeof callback !== "function"){ - throw new Error("Callback must be a function"); + throw new Error("File Store cache disabled - only asynchronous access supported"); } var storagePath = getStoragePath(this.storageBaseDir ,scope); loadFile(storagePath + ".json").then(function(data){ @@ -304,7 +304,7 @@ LocalFileSystem.prototype.set = function(scope, key, value, callback) { }, this.flushInterval); } } else if (callback && typeof callback !== 'function') { - throw new Error("Callback must be a function"); + throw new Error("File Store cache disabled - only asynchronous access supported"); } else { self.writePromise = self.writePromise.then(function() { return loadFile(storagePath + ".json") }).then(function(data){ var obj = data ? JSON.parse(data) : {}