Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions src/node/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ if (settings.dumpOnUncleanExit) {
const addProxyToAxios = (url: URL) => {
axios.defaults.proxy = {
host: url.hostname,
auth: {
username: url.username,
password: url.password,
},
port: Number(url.port),
protocol: url.protocol,
}
Expand Down
3 changes: 2 additions & 1 deletion src/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,13 @@
"find-root": "1.1.0",
"formidable": "^3.5.2",
"http-errors": "^2.0.0",
"https-proxy-agent": "^7.0.6",
"jose": "^5.10.0",
"js-cookie": "^3.0.5",
"jsdom": "^26.0.0",
"jsonminify": "0.4.2",
"jsonwebtoken": "^9.0.2",
"jwt-decode": "^4.0.0",
"languages4translatewiki": "0.1.3",
"live-plugin-manager": "^1.0.0",
"lodash.clonedeep": "4.5.0",
Expand All @@ -70,7 +72,6 @@
"socket.io-client": "^4.8.1",
"superagent": "10.2.0",
"swagger-ui-express": "^5.0.1",
"jwt-decode": "^4.0.0",
"tinycon": "0.6.8",
"tsx": "4.19.3",
"ueberdb2": "^5.0.6",
Expand Down
6 changes: 4 additions & 2 deletions src/static/js/pluginfw/installer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,12 +172,14 @@ export const getAvailablePlugins = (maxCacheAge: number|false) => {
}

await axios.get(`${settings.updateServer}/plugins.json`, {headers})
.then((pluginsLoaded:AxiosResponse<MapArrayType<PackageInfo>>) => {
.then((pluginsLoaded: AxiosResponse<MapArrayType<PackageInfo>>) => {
availablePlugins = pluginsLoaded.data;
cacheTimestamp = nowTimestamp;
resolve(availablePlugins);
})
.catch(async (err) => reject(err));
.catch(async (err) => {
logger.error(`Error fetching available plugins: ${err}`);

Copilot AI Apr 8, 2025

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The updated error handling logs the error without calling reject, which may leave the promise unresolved. Consider calling reject(err) or properly propagating the error after logging it.

Suggested change
logger.error(`Error fetching available plugins: ${err}`);
logger.error(`Error fetching available plugins: ${err}`);
reject(err);

Copilot uses AI. Check for mistakes.
});
});
};

Expand Down