mirror of
https://github.com/jxpeng98/obsidian-to-NotionNext
synced 2026-08-01 19:10:56 +08:00
fix: remove unnecessary resetAutoSyncNoticeCache call when autoSyncFrontmatterKey changes
This commit is contained in:
@@ -111,7 +111,6 @@ export class ObsidianSettingTab extends PluginSettingTab {
|
|||||||
.onChange(async (value) => {
|
.onChange(async (value) => {
|
||||||
this.plugin.settings.autoSyncFrontmatterKey = value;
|
this.plugin.settings.autoSyncFrontmatterKey = value;
|
||||||
await this.plugin.saveSettings();
|
await this.plugin.saveSettings();
|
||||||
this.plugin.resetAutoSyncNoticeCache();
|
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -137,7 +136,7 @@ export class ObsidianSettingTab extends PluginSettingTab {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
// Set initial visibility
|
// Set initial visibility
|
||||||
this.updateAutoSyncDelayVisibility();
|
this.updateAutoSyncDelayVisibility();
|
||||||
|
|
||||||
@@ -239,7 +238,7 @@ export class ObsidianSettingTab extends PluginSettingTab {
|
|||||||
this.plugin.settings[settingsKey] = value; // Update the plugin settings directly
|
this.plugin.settings[settingsKey] = value; // Update the plugin settings directly
|
||||||
await this.plugin.saveSettings();
|
await this.plugin.saveSettings();
|
||||||
await this.plugin.commands.updateCommand();
|
await this.plugin.commands.updateCommand();
|
||||||
|
|
||||||
// If autoSync setting changed, update the listener and visibility
|
// If autoSync setting changed, update the listener and visibility
|
||||||
if (settingsKey === 'autoSync') {
|
if (settingsKey === 'autoSync') {
|
||||||
this.plugin.setupAutoSync();
|
this.plugin.setupAutoSync();
|
||||||
|
|||||||
Reference in New Issue
Block a user