Skip to content

Commit 350db91

Browse files
committed
fix: fixed project initialization not allowing access to the plug-in interface, causing the page to continue loading #1162
1 parent 8e3ce7d commit 350db91

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

ui/src/utils/pluginKit/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ class Plugins {
5656
async init() {
5757
this.registerBuiltin();
5858

59-
const plugins = await getPluginsStatus().catch(() => []);
59+
// Note: The /install stage does not allow access to the getPluginsStatus api, so an initial value needs to be given
60+
const plugins = (await getPluginsStatus().catch(() => [])) || [];
6061
this.registeredPlugins = plugins.filter((p) => p.enabled);
6162
await this.registerPlugins();
6263
}
@@ -169,6 +170,7 @@ const validateRoutePlugin = async (slugName) => {
169170

170171
const mergeRoutePlugins = async (routes) => {
171172
const routePlugins = await getRoutePlugins();
173+
console.log('routePlugins', routePlugins);
172174
if (routePlugins.length === 0) {
173175
return routes;
174176
}

0 commit comments

Comments
 (0)