mirror of
https://github.com/Stremio/stremio-web.git
synced 2026-04-24 23:13:55 +00:00
check if library is loaded
This commit is contained in:
parent
f70ca3d293
commit
6aced6fc0e
2 changed files with 2 additions and 2 deletions
|
|
@ -38,7 +38,7 @@ const Library = ({ urlParams, queryParams }) => {
|
||||||
:
|
:
|
||||||
error !== null ?
|
error !== null ?
|
||||||
<div className={styles['message-container']}>
|
<div className={styles['message-container']}>
|
||||||
No items for type {urlParams.type !== (null && '') ? urlParams.type : '"Empty"'}
|
{error}
|
||||||
</div>
|
</div>
|
||||||
:
|
:
|
||||||
Array.isArray(metaItems) ?
|
Array.isArray(metaItems) ?
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ const useLibrary = (urlParams) => {
|
||||||
window.location.replace(`#/library/${event.value}${search !== null ? search : ''}`);
|
window.location.replace(`#/library/${event.value}${search !== null ? search : ''}`);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const error = state.library.items === 0 ? state.library.items : null;
|
const error = state.ctx.library.Ready.type !== 'Ready' ? state.ctx.library.Ready.type : null;
|
||||||
setLibrary([state.library.items, selectInput, error]);
|
setLibrary([state.library.items, selectInput, error]);
|
||||||
};
|
};
|
||||||
core.on('NewModel', onNewState);
|
core.on('NewModel', onNewState);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue