completionId: cgen-87479be916654f4999cc7c1417293a31
cgen-87479be916654f4999cc7c1417293a31
This commit is contained in:
parent
031e807db0
commit
e047073ce0
1 changed files with 2 additions and 5 deletions
|
|
@ -377,8 +377,7 @@ export default function Dashboard() {
|
||||||
applicationsResult,
|
applicationsResult,
|
||||||
achievementsResult,
|
achievementsResult,
|
||||||
followerCountResult,
|
followerCountResult,
|
||||||
] = await Promise.race([
|
] = await Promise.allSettled([
|
||||||
Promise.allSettled([
|
|
||||||
// Projects
|
// Projects
|
||||||
aethexProjectService.getUserProjects(userId).catch(() => []),
|
aethexProjectService.getUserProjects(userId).catch(() => []),
|
||||||
// Teams
|
// Teams
|
||||||
|
|
@ -412,9 +411,7 @@ export default function Dashboard() {
|
||||||
.eq("following_id", userId)
|
.eq("following_id", userId)
|
||||||
.then(({ count }) => typeof count === "number" ? count : 0)
|
.then(({ count }) => typeof count === "number" ? count : 0)
|
||||||
.catch(() => 0),
|
.catch(() => 0),
|
||||||
]),
|
]);
|
||||||
timeoutPromise,
|
|
||||||
]) as any[];
|
|
||||||
|
|
||||||
// Extract results from settled promises
|
// Extract results from settled promises
|
||||||
const userProjects = projectsResult.status === "fulfilled" ? projectsResult.value : [];
|
const userProjects = projectsResult.status === "fulfilled" ? projectsResult.value : [];
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue