@jambonz/node-red-contrib-jambonz 2.6.1 → 2.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jambonz/node-red-contrib-jambonz",
3
- "version": "2.6.1",
3
+ "version": "2.6.2",
4
4
  "description": "Node-RED nodes for jambonz platform",
5
5
  "keywords": [
6
6
  "node-red"
package/src/nodes/dial.js CHANGED
@@ -73,8 +73,12 @@ module.exports = function(RED) {
73
73
  data.boostAudioSignal = await new_resolve(RED, config.boostaudiosignal, config.boostaudiosignalType, node, msg)
74
74
  }
75
75
 
76
- if (config.forwardPAI != 'default') {
77
- data.forwardPAI = JSON.parse(config.forwardPAI);
76
+ if (config.forwardPAI !== undefined && config.forwardPAI !== 'default') {
77
+ if (config.forwardPAI === 'true' || config.forwardPAI === 'false') {
78
+ data.forwardPAI = config.forwardPAI === 'true';
79
+ } else {
80
+ node.warn(`Invalid forwardPAI value: ${config.forwardPAI}`);
81
+ }
78
82
  }
79
83
  // headers
80
84
  const headers = {};