From 2d4a2983bc343173175f8fe07974b1dd7d696c6d Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Thu, 19 Jan 2023 18:54:46 +1000 Subject: [PATCH] Avoid resetting current endpoint when custom endpoint has not changed --- qt/aqt/profiles.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/qt/aqt/profiles.py b/qt/aqt/profiles.py index c2a880c29..386d6a32c 100644 --- a/qt/aqt/profiles.py +++ b/qt/aqt/profiles.py @@ -665,8 +665,9 @@ create table if not exists profiles return self.profile.get("customSyncUrl") def set_custom_sync_url(self, url: str | None) -> None: - self.set_current_sync_url(None) - self.profile["customSyncUrl"] = url + if url != self.custom_sync_url(): + self.set_current_sync_url(None) + self.profile["customSyncUrl"] = url def auto_sync_media_minutes(self) -> int: return self.profile.get("autoSyncMediaMinutes", 15)