From 40520344778a98c45817e9cbc00caab6ec3ea6bf Mon Sep 17 00:00:00 2001 From: Jan Date: Sun, 30 Jul 2023 01:24:18 +0200 Subject: refactor: Add Profile to GameInstall (#453) Add Profile to GameInstall Replace hardcoded uses of R2Northstar with profile attribute --- src-vue/src/plugins/store.ts | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src-vue/src/plugins/store.ts') diff --git a/src-vue/src/plugins/store.ts b/src-vue/src/plugins/store.ts index 37d0d89d..2991ad1d 100644 --- a/src-vue/src/plugins/store.ts +++ b/src-vue/src/plugins/store.ts @@ -370,6 +370,12 @@ async function _initializeApp(state: any) { && persistent_game_install.value.game_path !== undefined && persistent_game_install.value.install_type !== undefined ) { // For some reason, the plugin-store doesn't throw an eror but simply returns `null` when key not found + + // Add profile to existing storage + if (persistent_game_install.value.profile === undefined) { + persistent_game_install.value.profile = "R2Northstar" + } + let game_install = persistent_game_install.value as GameInstall; // check if valid path let is_valid_titanfall2_install = await invoke("verify_install_location", { gamePath: game_install.game_path }) as boolean; -- cgit v1.2.3