mirror of
https://github.com/home-assistant/frontend.git
synced 2025-12-20 02:38:53 +00:00
computeLovelaceEntityName(): allow "number" names to be processed (#28231)
* allow "number" names to be processed * Apply suggestion from @MindFreeze --------- Co-authored-by: Petar Petrov <MindFreeze@users.noreply.github.com>
This commit is contained in:
@@ -21,8 +21,8 @@ export const computeLovelaceEntityName = (
|
||||
if (!config) {
|
||||
return stateObj ? computeStateName(stateObj) : "";
|
||||
}
|
||||
if (typeof config === "string") {
|
||||
return config;
|
||||
if (typeof config !== "object") {
|
||||
return String(config);
|
||||
}
|
||||
if (stateObj) {
|
||||
return hass.formatEntityName(stateObj, config);
|
||||
|
||||
Reference in New Issue
Block a user