[knx] Fix DPT 10 handling (#15082)
Signed-off-by: Karel Goderis <karel.goderis@me.com>
This commit is contained in:
parent
4eec1a7f47
commit
14726013b1
|
@ -215,8 +215,11 @@ public class ValueDecoder {
|
|||
try {
|
||||
date = new SimpleDateFormat(TIME_DAY_FORMAT, Locale.US).parse(value);
|
||||
} catch (ParseException pe) {
|
||||
date = new SimpleDateFormat(TIME_FORMAT, Locale.US).parse(value);
|
||||
throw pe;
|
||||
try {
|
||||
date = new SimpleDateFormat(TIME_FORMAT, Locale.US).parse(value);
|
||||
} catch (ParseException pe2) {
|
||||
throw pe2;
|
||||
}
|
||||
}
|
||||
return DateTimeType.valueOf(new SimpleDateFormat(DateTimeType.DATE_PATTERN).format(date));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue