Skip to content

Commit

Permalink
Numeric unique id (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
Zoe authored Aug 7, 2024
1 parent 18173c9 commit 50c65e4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@digital-alchemy/hass",
"repository": "https://github.com/Digital-Alchemy-TS/hass",
"homepage": "https://docs.digital-alchemy.app",
"version": "24.7.6",
"version": "24.8.1",
"scripts": {
"build": "rm -rf dist/; tsc",
"lint": "eslint src",
Expand Down
2 changes: 1 addition & 1 deletion src/extensions/config.extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export function Configure({

let services: HassServiceDTO[];
async function loadServiceList(recursion = START): Promise<void> {
logger.info({ name: loadServiceList }, `fetching service list`);
logger.debug({ name: loadServiceList }, `fetching service list`);
services = await hass.fetch.listServices();
if (is.empty(services)) {
if (recursion > MAX_ATTEMPTS) {
Expand Down
2 changes: 1 addition & 1 deletion src/extensions/entity.extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ export function EntityManager({
const unique_id = hass.entity.registry.current.find(
i => i.entity_id === entity_id,
)?.unique_id;
if (!is.empty(unique_id)) {
if (is.number(unique_id) || !is.empty(unique_id)) {
event.emit(unique_id, new_state, old_state);
}
}
Expand Down

0 comments on commit 50c65e4

Please sign in to comment.