1
0
mirror of https://github.com/node-red/node-red-nodes.git synced 2023-10-10 13:36:58 +02:00

Updated way main RED settings loaded

This commit is contained in:
Andrew Lindsay 2013-11-13 22:23:26 +00:00
parent 8b29841f97
commit 20aa487068

View File

@ -24,7 +24,7 @@ var util = require('util');
// module.exports = { account:'My-ACCOUNT-SID', authtoken:'TWILIO-TOKEN',from:'FROM-NUMBER' }
try {
var twiliokey = require(process.env.NODE_RED_HOME+"/settings").twilio || require(process.env.NODE_RED_HOME+"/../twiliokey.js");
var twiliokey = RED.settings.twilio || require(process.env.NODE_RED_HOME+"/../twiliokey.js");
}
catch(err) {
util.log("[56-twilio.js] Error: Failed to load Twilio credentials");