refactored entity listener so that live events actually come in
This commit is contained in:
1 parent
57c86093a4
commit
883955e523
12 files changed
+214
-266
No files matched your search
@@ -17,20 +17,10 @@ export const useMockHAEntities = (args: MockHAEntitiesProps) => {
|
||||
{
|
||||
additional: {},
|
||||
ready: false,
|
||||
collection: {
|
||||
state: {},
|
||||
refresh: () => new Promise(() => {}),
|
||||
subscribe: () => () => {},
|
||||
},
|
||||
},
|
||||
{
|
||||
additional: {},
|
||||
ready: false,
|
||||
collection: {
|
||||
state: {},
|
||||
refresh: () => new Promise(() => {}),
|
||||
subscribe: () => () => {},
|
||||
},
|
||||
}
|
||||
);
|
||||
} else {
|
||||
@@ -38,20 +28,12 @@ export const useMockHAEntities = (args: MockHAEntitiesProps) => {
|
||||
{
|
||||
additional: {},
|
||||
ready: true,
|
||||
collection: {
|
||||
state: args.entities,
|
||||
refresh: () => new Promise(() => {}),
|
||||
subscribe: () => () => {},
|
||||
},
|
||||
collection: args.entities,
|
||||
},
|
||||
{
|
||||
additional: {},
|
||||
ready: true,
|
||||
collection: {
|
||||
state: args.entitySource,
|
||||
refresh: () => new Promise(() => {}),
|
||||
subscribe: () => () => {},
|
||||
},
|
||||
collection: args.entitySource,
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user