From 88230f2c79ed5713994b0817b64b956cf07b60ad Mon Sep 17 00:00:00 2001 From: Remy Raes Date: Fri, 2 Dec 2022 01:17:25 +0100 Subject: fix: do not display deprecated mods in thunderstore view --- src-vue/src/plugins/store.ts | 4 +++- src-vue/src/utils/thunderstore/ThunderstoreMod.d.ts | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src-vue/src/plugins/store.ts b/src-vue/src/plugins/store.ts index e2246c44..3d55d2a4 100644 --- a/src-vue/src/plugins/store.ts +++ b/src-vue/src/plugins/store.ts @@ -229,7 +229,9 @@ export const store = createStore({ // Remove some mods from listing const removedMods = ['Northstar', 'NorthstarReleaseCandidate', 'r2modman']; - state.thunderstoreMods = mods.filter((mod: ThunderstoreMod) => !removedMods.includes(mod.name)); + state.thunderstoreMods = mods.filter((mod: ThunderstoreMod) => { + return !removedMods.includes(mod.name) && !mod.is_deprecated; + }); }, async loadInstalledMods(state: FlightCoreStore) { let game_install = { diff --git a/src-vue/src/utils/thunderstore/ThunderstoreMod.d.ts b/src-vue/src/utils/thunderstore/ThunderstoreMod.d.ts index c14a83a0..6fddd06f 100644 --- a/src-vue/src/utils/thunderstore/ThunderstoreMod.d.ts +++ b/src-vue/src/utils/thunderstore/ThunderstoreMod.d.ts @@ -5,5 +5,6 @@ export interface ThunderstoreMod { owner: string; rating_score: number; package_url: string; + is_deprecated: boolean; versions: ThunderstoreModVersion[]; } -- cgit v1.2.3