From 5d9661cee575ad6e8ddfaa29cda3a5b1029634f4 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Sun, 19 Jan 2020 14:04:57 +1000 Subject: [PATCH] update add-ons even if they're disabled If a user enables an old add-on and restarts immediately, it won't have had a chance to update, and may raise errors that could have been prevented if the user was running the latest version. --- qt/aqt/addons.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qt/aqt/addons.py b/qt/aqt/addons.py index 6d393dc71..f770899b2 100644 --- a/qt/aqt/addons.py +++ b/qt/aqt/addons.py @@ -248,10 +248,10 @@ and have been disabled: %(found)s" addon.enabled = should_enable self.write_addon_meta(addon) - def enabled_ankiweb_addons(self) -> List[int]: + def ankiweb_addons(self) -> List[int]: ids = [] for meta in self.all_addon_meta(): - if meta.ankiweb_id() is not None and meta.enabled: + if meta.ankiweb_id() is not None: ids.append(meta.ankiweb_id()) return ids @@ -1041,7 +1041,7 @@ def check_for_updates( client = HttpClient() def check(): - return fetch_update_info(client, mgr.enabled_ankiweb_addons()) + return fetch_update_info(client, mgr.ankiweb_addons()) def update_info_received(future: Future): # if syncing/in profile screen, defer message delivery