From 04e8c3b15d4292067f32b692192d8bebb5f6eb93 Mon Sep 17 00:00:00 2001 From: Miguel Jacq Date: Thu, 18 Jan 2018 08:43:14 +1100 Subject: [PATCH] Re-load the settings in the UpdateCheck thread before saving, in case settings have changed in between starting thread and saving, so we don't clobber them --- onionshare_gui/update_checker.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/onionshare_gui/update_checker.py b/onionshare_gui/update_checker.py index 57fda0bd..ca2eb48a 100644 --- a/onionshare_gui/update_checker.py +++ b/onionshare_gui/update_checker.py @@ -130,6 +130,8 @@ class UpdateChecker(QtCore.QObject): # Update the last checked timestamp (dropping the seconds and milliseconds) timestamp = datetime.datetime.now().replace(microsecond=0).replace(second=0).timestamp() + # Re-load the settings first before saving, just in case they've changed since we started our thread + settings.load() settings.set('autoupdate_timestamp', timestamp) settings.save()