1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00
node-red/packages/node_modules/@node-red/nodes
Alexandre Alapetite e55cbb3e3d
Fix bug in debug node due to msg.hasOwnProperty construct
`msg.hasOwnProperty("status")` might make the debug node crash/produce an error if the payload was created with `Object.create(null)`.
This is the case e.g. for `ini` (to parse INI files), an official NPM node:
4f289946b3/lib/ini.js (L63)

My Node-RED node `node-red-contrib-parser-ini`, which is using that library, was hit by this bug and I had to ship a workaround
fe6b1eb4b1/parser-ini.js (L14)

The `msg.hasOwnProperty("xxx")` construct should not be used since ECMAScript 5.1.

ESLint advises in the same direction https://eslint.org/docs/rules/no-prototype-builtins

This patch was produced using the following regex:
Search: `\b([\w.]+).hasOwnProperty\(`
Replace: `Object.prototype.hasOwnProperty.call($1, `

This could be applied more gobally if desired.
2022-02-03 02:01:22 +01:00
..
core Fix bug in debug node due to msg.hasOwnProperty construct 2022-02-03 02:01:22 +01:00
examples Merge pull request #3336 from node-red-hitachi/add-link-call-example 2022-01-12 17:31:57 +00:00
icons Add link-call node and add return mode for link-out node 2021-09-29 10:45:00 +01:00
locales Add Japanese translations for v2.2.0 2022-01-27 11:14:24 +09:00
.npmignore Add pack-modules grunt task 2018-10-25 11:18:13 +01:00
99-sample.html.demo Add placeholder to topic field 2019-10-30 19:39:38 +09:00
99-sample.js.demo WIP: move all the code 2018-08-04 22:23:06 +01:00
index.js pull out editor-client and editor-api 2018-08-17 22:10:54 +01:00
LICENSE Update package readmes and licenses 2022-01-27 12:49:48 +00:00
package.json Update version for 2.2.0 2022-01-27 10:13:28 +00:00
README.md Add README files to each package 2018-08-21 13:43:11 +01:00

@node-red/nodes

Node-RED core nodes module.

This provides all of the core Node-RED nodes.

Source

The main Node-RED modules are maintained as a monorepo on GitHub.