Skip to content

Commit

Permalink
read/write/notification: on error debug points to the correct node an…
Browse files Browse the repository at this point in the history
…d varame in debug message
  • Loading branch information
PLCHome committed Apr 29, 2019
1 parent 20e363c commit 3b230b3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
**Enhancements**

- something about issue
- read/write/notification: on error debug points to the correct node and varame in debug message

### 1.1.22: Maintenance Release

Expand Down
6 changes: 3 additions & 3 deletions ads-connection.js
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ module.exports = function (RED) {
node.notificationSubscribed[n.symname].push(n)
node.adsClient.notify(handle, function(err){
if (err){
node.error(util.format('Ads Register Notification %s', err))
n.error(util.format("Ads Register Notification '%s' %s",n.symname, err))
} else {
node.notificationSubscribed[n.symname].map((no)=>{
no.notifyHandle = handle.notifyHandle
Expand Down Expand Up @@ -314,7 +314,7 @@ module.exports = function (RED) {
node.adsClient.write(handle,
function (err){
if (err) {
node.error(util.format('Ads write %s', err))
n.error(util.format("Ads write '%s' %s", config.symname,err))
}
} )
}
Expand Down Expand Up @@ -346,7 +346,7 @@ module.exports = function (RED) {
debug('read:',handle)
node.adsClient.read(handle, function(err, handle){
if (err) {
node.error(util.format('Ads read %s', err))
n.error(util.format("Ads read '%s' %s",config.symname, err))
} else {
cb(handle)
}
Expand Down

0 comments on commit 3b230b3

Please sign in to comment.