mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Update file, http and email nodes to only show deprecation warning
if msg property is a real overide to node property ( !== ). Fix for comment by @drJeckyll to Issue #399
This commit is contained in:
@@ -27,7 +27,7 @@ module.exports = function(RED) {
|
||||
this.on("input",function(msg) {
|
||||
var filename;
|
||||
if (msg.filename) {
|
||||
if (n.filename) {
|
||||
if (n.filename && (n.filename !== msg.filename)) {
|
||||
node.warn("Deprecated: msg properties should not override set node properties. See bit.ly/nr-override-msg-props");
|
||||
}
|
||||
filename = msg.filename;
|
||||
@@ -89,7 +89,7 @@ module.exports = function(RED) {
|
||||
this.on("input",function(msg) {
|
||||
var filename;
|
||||
if (msg.filename) {
|
||||
if (n.filename) {
|
||||
if (n.filename && (n.filename !== msg.filename)) {
|
||||
node.warn("Deprecated: msg properties should not override set node properties. See bit.ly/nr-override-msg-props");
|
||||
}
|
||||
filename = msg.filename;
|
||||
|
Reference in New Issue
Block a user