Skip to content

Commit

Permalink
Use Vuex when disabling all mods from settings page
Browse files Browse the repository at this point in the history
This significantly speeds up the process.
  • Loading branch information
anttimaki committed Feb 22, 2024
1 parent 578ab72 commit 156e0e5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/pages/Manager.vue
Original file line number Diff line number Diff line change
Expand Up @@ -572,7 +572,7 @@ import CategoryFilterModal from '../components/modals/CategoryFilterModal.vue';
});
}
handleSettingsCallbacks(invokedSetting: any) {
async handleSettingsCallbacks(invokedSetting: any) {
switch(invokedSetting) {
case "BrowseDataFolder":
this.browseDataFolder();
Expand Down Expand Up @@ -628,7 +628,11 @@ import CategoryFilterModal from '../components/modals/CategoryFilterModal.vue';
this.setAllModsEnabled(true);
break;
case "DisableAll":
this.setAllModsEnabled(false);
await this.$store.dispatch(
"profile/disableModsFromActiveProfile",
{mods: this.$store.state.localModList}
);
await this.$router.push({name: "manager.installed"});
break;
case "UpdateAllMods":
this.$store.commit("openUpdateAllModsModal");
Expand Down

0 comments on commit 156e0e5

Please sign in to comment.