mirror of
https://github.com/Ingan121/Vineless.git
synced 2026-04-02 18:48:40 +00:00
* Don't show the reload button when editing profiles of another site
* Fix typo in the codebase
This commit is contained in:
@@ -447,9 +447,11 @@ async function applyConfig() {
|
||||
// If Vineless is globally disabled, per-site enabled config is completely ignored
|
||||
// Enable both global and per-site when switching the per-site one to enabled, if global was disabled
|
||||
if (scope === "global" || (config.enabled && !await SettingsManager.getGlobalEnabled())) {
|
||||
await SettingsManager.setGlobalEnalbed(config.enabled);
|
||||
await SettingsManager.setGlobalEnabled(config.enabled);
|
||||
}
|
||||
if (!siteScopeLabel.dataset.hostOverride) {
|
||||
reloadButton.classList.remove('hidden');
|
||||
}
|
||||
reloadButton.classList.remove('hidden');
|
||||
updateIcon();
|
||||
}
|
||||
|
||||
|
||||
2
util.js
2
util.js
@@ -408,7 +408,7 @@ export class SettingsManager {
|
||||
return config.enabled;
|
||||
}
|
||||
|
||||
static async setGlobalEnalbed(enabled) {
|
||||
static async setGlobalEnabled(enabled) {
|
||||
const config = await SettingsManager.getProfile("global");
|
||||
config.enabled = enabled;
|
||||
setIcon(`images/icon${enabled ? '' : '-disabled'}.png`);
|
||||
|
||||
Reference in New Issue
Block a user