[arch] fixes -> not displaying installed AUR packages when AUR support is disabled | downloading AUR index during the initialization process when AUR support is disabled

This commit is contained in:
Vinicius Moreira
2021-01-12 16:06:34 -03:00
parent d912eb3aef
commit af6367b0ab
4 changed files with 83 additions and 49 deletions

View File

@@ -44,6 +44,9 @@ class AURIndexUpdater(Thread):
self.taskman.register_task(self.task_id, self.i18n['arch.task.aur.index.status'], get_icon_path())
def should_update(self) -> bool:
if not aur.is_supported(self.config):
return False
try:
exp_hours = int(self.config['aur_idx_exp'])
except:
@@ -134,7 +137,7 @@ class AURIndexUpdater(Thread):
tf = time.time()
self.taskman.finish_task(self.task_id)
self.logger.info("Finished. Took {0:.2f} seconds".format(tf - ti))
self.logger.info("Finished. Took {0:.5f} seconds".format(tf - ti))
class ArchDiskCacheUpdater(Thread):