Skip to content

Commit 35a64d5

Browse files
authored
filter .DS_Store from addons before checking if none are found
1 parent 12f4c85 commit 35a64d5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

client/src/addon_manager/services/addonManager.service.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,13 @@ class AddonManager {
3333

3434
const ignoreList = [".DS_Store"];
3535
let addons = await filesystem.readDirectory(installLocation);
36+
if (addons) {
37+
addons = addons.filter((a) => !ignoreList.includes(a.name));
38+
}
3639
if (!addons) {
3740
localLogger.warn("No addons found in installation folder");
3841
return;
3942
}
40-
addons = addons.filter((a) => !ignoreList.includes(a.name));
4143
for (const addon of addons) {
4244
this.addons.set(addon.name, new Addon(addon.name, addon.uri));
4345
localLogger.verbose(`Found ${addon.name}`);

0 commit comments

Comments
 (0)