loxone-java
loxone-java copied to clipboard
Failed HTTP get for typed command can lead to ClassCastException
For instance DEV_SYS_CPU command should carry PercentValue however in case of failure (i.e. unsufficient permissions) the JsonValue is returned instead. Since LoxoneHttp.get() is type parametrized, the ClassCastException happens later when trying to access returned LoxoneMessage.value