Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
vamsee committed Oct 6, 2020
2 parents a540b00 + 5e1e622 commit 32f709c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion create-data/create-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ module.exports = function (RED) {
var msgPayload;
if (msg.payload) {
try {
msgPayload = JSON.parse(msg.payload);
msgPayload = (typeof msg.payload === 'string') ? JSON.parse(msg.payload) : msg.payload;
} catch (exp) { msgPayload = false;}
}
if (msgPayload) {
Expand Down
10 changes: 5 additions & 5 deletions find-data/find-data.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ module.exports = function (RED) {
'text': 'Found ' + response.length + ' records'
});
msg.resultModelName = modelName;
response.forEach(function (instance, index) {
if (instance instanceof Model) {
response[index] = response[index].toObject();
}
});
// response.forEach(function (instance, index) {
// if (instance instanceof Model) {
// response[index] = response[index].toObject();
// }
// });
msg.payload = response;
node.send([msg, null]);
}
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "oe-node-red-nodes",
"version": "2.2.0",
"version": "2.3.0",
"description": "Node-RED nodes for oeCloud based applications",
"main": "node-red.js",
"scripts": {
Expand Down Expand Up @@ -42,7 +42,7 @@
"license": "MIT",
"dependencies": {
"async": "2.6.1",
"lodash": "4.17.14"
"lodash": "4.17.20"
},
"devDependencies": {
"babel-eslint": "7.2.3",
Expand Down

0 comments on commit 32f709c

Please sign in to comment.