Skip to content

Commit a754f46

Browse files
authored
Merge pull request #56 from sinricpro/4.0.0-dev
fix: logging
2 parents 31fb9b4 + 782b7e2 commit a754f46

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

examples/switch-js/index.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,7 @@ async function main() {
3434
// This is called when Alexa/Google Home sends a command
3535
mySwitch.onPowerState(async (deviceId, state) => {
3636
console.log(`\n[Callback] Device ${deviceId} turned ${state ? 'ON' : 'OFF'}`);
37-
console.log(' Source: Alexa/Google Home/SinricPro App');
38-
37+
3938
// Update local state
4039
devicePowerState = state;
4140

@@ -44,9 +43,6 @@ async function main() {
4443
// - GPIO.write(LED_PIN, state);
4544
// - relay.setState(state);
4645
// - httpRequest('http://192.168.1.100/switch', { state });
47-
48-
console.log(` Action: Simulated hardware is now ${state ? 'ON' : 'OFF'}`);
49-
5046
return true; // Return true if successful, false if failed
5147
});
5248

0 commit comments

Comments
 (0)