@5minds/node-red-contrib-processcube 0.5.6-develop-a98283-lxrzpgvk → 0.5.7-develop-9cb5f7-lxu2vowj

Sign up to get free protection for your applications and to get access to all the features.
@@ -10,11 +10,18 @@ module.exports = function(RED) {
10
10
 
11
11
  const externalTaskId = msg.externalTaskId;
12
12
 
13
+ let error = msg.error;
14
+
15
+ if (error === undefined) {
16
+ error.message = "An error occurred";
17
+ error.source = msg.payload;
18
+ }
19
+
13
20
  msg.payload = {
14
21
  "error": {
15
22
  errorCode: config.error,
16
- errorMessage: msg.error.message,
17
- errorDetails: msg.error.source
23
+ errorMessage: error.message,
24
+ errorDetails: error.source
18
25
  }
19
26
  };
20
27
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@5minds/node-red-contrib-processcube",
3
- "version": "0.5.6-develop-a98283-lxrzpgvk",
3
+ "version": "0.5.7-develop-9cb5f7-lxu2vowj",
4
4
  "license": "MIT",
5
5
  "description": "Node-RED nodes for ProcessCube",
6
6
  "authors": [