Skip to content

Commit

Permalink
remove some warnings which should only be debug log
Browse files Browse the repository at this point in the history
- closes ioBroker#709, closes ioBroker#730
  • Loading branch information
foxriver76 committed Apr 11, 2024
1 parent 18ef821 commit 8dddd62
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,9 @@ setState('iot.0.app.message', JSON.stringify({
-->

## Changelog
### **WORK IN PROGRESS**
* (foxriver76) remove some warnings which should only be debug log

### 3.2.1 (2024-04-11)
* (foxriver76) fixed issue that only valid JSON could be sent to app via message state

Expand Down
6 changes: 4 additions & 2 deletions lib/alexaSmartHomeV2.js
Original file line number Diff line number Diff line change
Expand Up @@ -506,11 +506,13 @@ function AlexaSH2(adapter) {
let byON = (smartName && typeof smartName === 'object') ? smartName.byON : null;

if (toggle && toggle !== id) {
throw new Error(`Won't control ${id} as we have a switch available`);
adapter.log.debug(`Won't control ${id} as we have a switch available`);
return
}

if (byON === 'omit') {
throw new Error(`Won't control value for "${id}", because "omit" configured`);
adapter.log.debug(`Won't control value for "${id}", because "omit" configured`);
return
}

if (obj.common.type === 'number') {
Expand Down

0 comments on commit 8dddd62

Please sign in to comment.