mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-16 02:30:11 +00:00
fix(dashboard): fix endless loading of lists that failed to fetch
This commit is contained in:
parent
19560f09c2
commit
30dd95674d
1 changed files with 6 additions and 2 deletions
|
|
@ -69,6 +69,8 @@
|
||||||
|
|
||||||
// fetch both lists, and store them inside a context store
|
// fetch both lists, and store them inside a context store
|
||||||
async function fetchLists() {
|
async function fetchLists() {
|
||||||
|
errs.members = null;
|
||||||
|
errs.groups = null;
|
||||||
loading.members = true;
|
loading.members = true;
|
||||||
loading.groups = true;
|
loading.groups = true;
|
||||||
|
|
||||||
|
|
@ -80,6 +82,7 @@
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
errs.members = error.message;
|
errs.members = error.message;
|
||||||
|
loading.members = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
@ -90,6 +93,7 @@
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
errs.groups = error.message;
|
errs.groups = error.message;
|
||||||
|
loading.groups = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -132,10 +136,10 @@
|
||||||
<SystemMain bind:user={user} isPublic={true} />
|
<SystemMain bind:user={user} isPublic={true} />
|
||||||
</TabPane>
|
</TabPane>
|
||||||
<TabPane tabId="members" tab="Members" active={tabPane === "members"}>
|
<TabPane tabId="members" tab="Members" active={tabPane === "members"}>
|
||||||
<MemberList on:viewChange={(e) => navigateTo("members", e.detail)} bind:listLoading={loading.members} pageOptions={memberListPageOptions} options={memberListOptions} {systemId} />
|
<MemberList on:viewChange={(e) => navigateTo("members", e.detail)} bind:listLoading={loading.members} pageOptions={memberListPageOptions} options={memberListOptions} {systemId} err={errs.members} />
|
||||||
</TabPane>
|
</TabPane>
|
||||||
<TabPane tabId="groups" tab="Groups" active={tabPane === "groups"}>
|
<TabPane tabId="groups" tab="Groups" active={tabPane === "groups"}>
|
||||||
<GroupList on:viewChange={(e) => navigateTo("groups", e.detail)} bind:listLoading={loading.groups} pageOptions={groupListPageOptions} options={groupListOptions} {systemId} />
|
<GroupList on:viewChange={(e) => navigateTo("groups", e.detail)} bind:listLoading={loading.groups} pageOptions={groupListPageOptions} options={groupListOptions} {systemId} err={errs.groups} />
|
||||||
</TabPane>
|
</TabPane>
|
||||||
</TabContent>
|
</TabContent>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue