mirror of
https://github.com/openhab/openhab-addons.git
synced 2025-01-27 07:41:39 +01:00
[hueemulation] Fixed nullpointer in adjustedColorStateFromItemState (#8560)
Signed-off-by: Nicolai Grødum <grodum@gmail.com>
This commit is contained in:
parent
cafa8fdcff
commit
9c16f3c6f5
@ -450,7 +450,8 @@ public class StateUtils {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if (lastCommand instanceof PercentType) {
|
} else if (lastCommand instanceof PercentType) {
|
||||||
if (hueState instanceof HueStateBulb && itemState.as(PercentType.class).equals(lastCommand)) {
|
if (hueState instanceof HueStateBulb && itemState != null
|
||||||
|
&& lastCommand.equals(itemState.as(PercentType.class))) {
|
||||||
if (lastHueChange.bri != null) {
|
if (lastHueChange.bri != null) {
|
||||||
((HueStateBulb) hueState).bri = lastHueChange.bri;
|
((HueStateBulb) hueState).bri = lastHueChange.bri;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user