mirror of
https://github.com/home-assistant/frontend.git
synced 2025-04-25 05:47:20 +00:00
Merge pull request #11729 from home-assistant/20220203.1
This commit is contained in:
commit
41ec65ef3d
@ -1,6 +1,6 @@
|
||||
[metadata]
|
||||
name = home-assistant-frontend
|
||||
version = 20220203.0
|
||||
version = 20220203.1
|
||||
author = The Home Assistant Authors
|
||||
author_email = hello@home-assistant.io
|
||||
license = Apache-2.0
|
||||
|
@ -123,7 +123,11 @@ export const computeStateDisplay = (
|
||||
domain === "scene" ||
|
||||
(domain === "sensor" && stateObj.attributes.device_class === "timestamp")
|
||||
) {
|
||||
return formatDateTime(new Date(compareState), locale);
|
||||
try {
|
||||
return formatDateTime(new Date(compareState), locale);
|
||||
} catch (_err) {
|
||||
return compareState;
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
|
@ -135,7 +135,9 @@ export class HaServiceControl extends LitElement {
|
||||
let updatedDefaultValue = false;
|
||||
if (this._value && serviceData) {
|
||||
// Set mandatory bools without a default value to false
|
||||
this._value.data ??= {};
|
||||
if (!this._value.data) {
|
||||
this._value.data = {};
|
||||
}
|
||||
serviceData.fields.forEach((field) => {
|
||||
if (
|
||||
field.selector &&
|
||||
|
Loading…
x
Reference in New Issue
Block a user