aboutsummaryrefslogtreecommitdiff
path: root/src-vue
diff options
context:
space:
mode:
authorJan <sentrycraft123@gmail.com>2023-07-30 01:24:18 +0200
committerGitHub <noreply@github.com>2023-07-30 01:24:18 +0200
commit40520344778a98c45817e9cbc00caab6ec3ea6bf (patch)
tree1b60a9ea7801734b27ac120c65c016ea1e38d4a7 /src-vue
parent399f0e78b4773aa97a8a80c43fb2312ea830a845 (diff)
downloadFlightCore-40520344778a98c45817e9cbc00caab6ec3ea6bf.tar.gz
FlightCore-40520344778a98c45817e9cbc00caab6ec3ea6bf.zip
refactor: Add Profile to GameInstall (#453)
Add Profile to GameInstall Replace hardcoded uses of R2Northstar with profile attribute
Diffstat (limited to 'src-vue')
-rw-r--r--src-vue/src/plugins/store.ts6
-rw-r--r--src-vue/src/utils/GameInstall.ts1
2 files changed, 7 insertions, 0 deletions
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;
diff --git a/src-vue/src/utils/GameInstall.ts b/src-vue/src/utils/GameInstall.ts
index 07358f6c..162d2860 100644
--- a/src-vue/src/utils/GameInstall.ts
+++ b/src-vue/src/utils/GameInstall.ts
@@ -1,4 +1,5 @@
export interface GameInstall {
game_path: string;
+ profile: string,
install_type: string;
}