Skip to content

Commit

Permalink
Fix wind bearing state when at 0 #52
Browse files Browse the repository at this point in the history
  • Loading branch information
kalkih committed May 11, 2022
1 parent 69a8646 commit ba123cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/weather.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ export default class WeatherEntity {
}

get wind_bearing() {
return this.attr.wind_bearing
return this.attr.wind_bearing !== "undefined"
? this.degToDirection(this.attr.wind_bearing)
: this.toLocale('state.default.unknown');
}
Expand Down

0 comments on commit ba123cf

Please sign in to comment.