mirror of
https://github.com/zen-browser/desktop.git
synced 2025-07-08 08:19:59 +02:00
Remove unnecessary repetition of the same action. (#8840)
I have removed the unnecessary repetition of what ```gZenMarketplaceManager._triggerBuildUpdateWithoutRebuild``` already does and replaced those situations with calls to that actual function. I have also rearranged that function to before the functions that call it so the flow makes more sense. Signed-off-by: CosmoCreeper <179134799+CosmoCreeper@users.noreply.github.com>
This commit is contained in:
parent
8f06bf21b0
commit
ab9a752286
1 changed files with 7 additions and 9 deletions
|
@ -131,6 +131,11 @@ var gZenMarketplaceManager = {
|
|||
return this._modsList;
|
||||
},
|
||||
|
||||
_triggerBuildUpdateWithoutRebuild() {
|
||||
this._doNotRebuildModsList = true;
|
||||
gZenMods.triggerModsUpdate();
|
||||
},
|
||||
|
||||
async removeMod(modId) {
|
||||
await gZenMods.removeMod(modId);
|
||||
|
||||
|
@ -140,20 +145,13 @@ var gZenMarketplaceManager = {
|
|||
async disableMod(modId) {
|
||||
await gZenMods.disableMod(modId);
|
||||
|
||||
this._doNotRebuildModsList = true;
|
||||
gZenMods.triggerModsUpdate();
|
||||
this._triggerBuildUpdateWithoutRebuild();
|
||||
},
|
||||
|
||||
async enableMod(modId) {
|
||||
await gZenMods.enableMod(modId);
|
||||
|
||||
this._doNotRebuildModsList = true;
|
||||
gZenMods.triggerModsUpdate();
|
||||
},
|
||||
|
||||
_triggerBuildUpdateWithoutRebuild() {
|
||||
this._doNotRebuildModsList = true;
|
||||
gZenMods.triggerModsUpdate();
|
||||
this._triggerBuildUpdateWithoutRebuild();
|
||||
},
|
||||
|
||||
async _importThemes() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue