mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Merge pull request #767 from appwrite/fix-race-condition-functions
fix: functions race condition for state
This commit is contained in:
2 files changed
+8
-5
No files matched your search
@@ -8,10 +8,15 @@ import type { LayoutLoad } from './$types';
|
||||
export const load: LayoutLoad = async ({ depends }) => {
|
||||
depends(Dependencies.FUNCTION_INSTALLATIONS);
|
||||
|
||||
const [runtimesList, installations] = await Promise.all([
|
||||
sdk.forProject.functions.listRuntimes(),
|
||||
sdk.forProject.vcs.listInstallations([Query.limit(100)])
|
||||
]);
|
||||
|
||||
return {
|
||||
header: Header,
|
||||
breadcrumbs: Breadcrumbs,
|
||||
runtimesList: sdk.forProject.functions.listRuntimes(),
|
||||
installations: sdk.forProject.vcs.listInstallations([Query.limit(100)])
|
||||
runtimesList,
|
||||
installations
|
||||
};
|
||||
};
|
||||
+1
-3
@@ -31,8 +31,6 @@ export const load: PageLoad = async ({ params, depends }) => {
|
||||
|
||||
return {
|
||||
variables,
|
||||
globalVariables,
|
||||
runtimesList: sdk.forProject.functions.listRuntimes(),
|
||||
installations: sdk.forProject.vcs.listInstallations()
|
||||
globalVariables
|
||||
};
|
||||
};
|
||||
Reference in new issue
Block a user