Skip to content

Commit

Permalink
Merge pull request #126 from blia/patch-2
Browse files Browse the repository at this point in the history
Update README.md
  • Loading branch information
aholstenson authored Mar 15, 2018
2 parents 6305c5b + cd434bc commit 111b2f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ Listen to events such as property changes and actions:
device.on('power', power => console.log('Power changed to', power));

// The device is available for event handlers
const handler = (action, device) => console.log('Action', e.action, 'performed on', device);
const handler = ({ action }, device) => console.log('Action', action, 'performed on', device);
device1.on('action', handler);
device2.on('action', handler);
```
Expand Down

0 comments on commit 111b2f2

Please sign in to comment.