mirror of
https://github.com/Skylar-Tech/node-red-contrib-matrix-chat.git
synced 2025-04-19 20:43:04 -06:00
use hasOwn instead of keys
This commit is contained in:
parent
d01838ac84
commit
2a78524a90
@ -127,7 +127,7 @@ module.exports = function(RED) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(msgFormat === 'msg.format') {
|
if(msgFormat === 'msg.format') {
|
||||||
if(!Object.keys(msg).includes("format")) {
|
if(!Object.hasOwn(msg, 'format')) {
|
||||||
node.error("Message format is set to be passed in via msg.format but was not defined", msg);
|
node.error("Message format is set to be passed in via msg.format but was not defined", msg);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user