mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Revert and force getSetting to use the local node
Co-authored-by: Nick O'Leary <nick.oleary@gmail.com>
This commit is contained in:
parent
2fd7aee4da
commit
f67268b89a
@ -22,11 +22,6 @@ module.exports = function(RED) {
|
|||||||
var acorn = require("acorn");
|
var acorn = require("acorn");
|
||||||
var acornWalk = require("acorn-walk");
|
var acornWalk = require("acorn-walk");
|
||||||
|
|
||||||
const envVarExcludes = {};
|
|
||||||
if (RED.settings.envVarExcludes && Array.isArray(RED.settings.envVarExcludes)) {
|
|
||||||
RED.settings.envVarExcludes.forEach((e) => envVarExcludes[e] = true);
|
|
||||||
}
|
|
||||||
|
|
||||||
function sendResults(node,send,_msgid,msgs,cloneFirstMessage) {
|
function sendResults(node,send,_msgid,msgs,cloneFirstMessage) {
|
||||||
if (msgs == null) {
|
if (msgs == null) {
|
||||||
return;
|
return;
|
||||||
@ -171,11 +166,9 @@ module.exports = function(RED) {
|
|||||||
RED: {
|
RED: {
|
||||||
util: {
|
util: {
|
||||||
...RED.util,
|
...RED.util,
|
||||||
getSetting: function (node, name, flow) {
|
getSetting: function (_node, name, _flow) {
|
||||||
if (envVarExcludes[name]) {
|
// Ensure `node` argument is the Function node and do not allow flow to be overridden.
|
||||||
return undefined;
|
return RED.util.getSetting(node, name);
|
||||||
}
|
|
||||||
return RED.util.getSetting(node, name, flow);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user