diff --git a/biome.json b/biome.json index 3032c758..c42cdf08 100644 --- a/biome.json +++ b/biome.json @@ -13,11 +13,9 @@ "indentWidth": 2, "lineWidth": 120, "lineEnding": "lf", - "include": ["**/*.ts", "**/*.json"], - "ignore": [".cache/**", "**/*.snap"], "attributePosition": "auto" }, - "files": { "include": ["**/*.ts", "**/*.json"] }, + "files": { "include": ["**/*.ts", "**/*.json"], "ignore": [".cache/**", "**/*.snap"] }, "linter": { "enabled": true, "rules": { diff --git a/src/actions/scan.ts b/src/actions/scan.ts index d1d477d3..e713d62a 100644 --- a/src/actions/scan.ts +++ b/src/actions/scan.ts @@ -132,28 +132,30 @@ export const processScanResults = ( ); } - unsure.push({ - configuredMod: findInConfiguration( - halfMatching[0].configured?.type, - halfMatching[0].configured?.id, - configuration - ), - configuredInstallation: installationIndex, - newMod: { - type: halfMatching[0].local.platform, - id: halfMatching[0].local.modId, - name: halfMatching[0].remote.name - } as Mod, - installation: { - hash: halfMatching[0].local.mod.hash, - fileName: halfMatching[0].local.mod.fileName, - name: halfMatching[0].remote.name, - type: halfMatching[0].local.platform, - id: halfMatching[0].local.modId, - releasedOn: halfMatching[0].local.mod.releaseDate, - downloadUrl: halfMatching[0].local.mod.downloadUrl - } as ModInstall - }); + if (halfMatching[0].remote) { + unsure.push({ + configuredMod: findInConfiguration( + halfMatching[0].configured?.type, + halfMatching[0].configured?.id, + configuration + ), + configuredInstallation: installationIndex, + newMod: { + type: halfMatching[0].local.platform, + id: halfMatching[0].local.modId, + name: halfMatching[0].remote.name + } as Mod, + installation: { + hash: halfMatching[0].local.mod.hash, + fileName: halfMatching[0].local.mod.fileName, + name: halfMatching[0].remote.name, + type: halfMatching[0].local.platform, + id: halfMatching[0].local.modId, + releasedOn: halfMatching[0].local.mod.releaseDate, + downloadUrl: halfMatching[0].local.mod.downloadUrl + } as ModInstall + }); + } } // ================================================================================================================