Skip to content

Commit

Permalink
fix: Prior to 0.90.0 is_admin doesn't exist check for it to exist and…
Browse files Browse the repository at this point in the history
… not true

Fixes #207
  • Loading branch information
zachowj committed Feb 24, 2020
1 parent 72c9c37 commit 3f07f55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/ha-websocket.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class HaWebsocket extends EventEmitter {

// Check if user has admin privileges
const user = await this.getUser();
if (!user.is_admin) {
if (user.is_admin === false) {
this.connectionState = HaWebsocket.ERROR;
this.client.close();
throw new Error(
Expand Down

0 comments on commit 3f07f55

Please sign in to comment.