diff --git a/youtube_dl_gui/Utils.py b/youtube_dl_gui/Utils.py index 7f1a5cf..f4e2820 100644 --- a/youtube_dl_gui/Utils.py +++ b/youtube_dl_gui/Utils.py @@ -141,4 +141,5 @@ def get_time(seconds): dtime['minutes'] = seconds % 86400 % 3600 / 60 dtime['seconds'] = seconds % 86400 % 3600 % 60 - return dtime \ No newline at end of file + return dtime + diff --git a/youtube_dl_gui/YoutubeDLGUI.py b/youtube_dl_gui/YoutubeDLGUI.py index 8dfa679..6d9eab3 100644 --- a/youtube_dl_gui/YoutubeDLGUI.py +++ b/youtube_dl_gui/YoutubeDLGUI.py @@ -184,7 +184,12 @@ class MainFrame(wx.Frame): def fin_tasks(self): if self.opt_manager.options['shutdown']: - shutdown_sys(self.opt_manager.options['sudo_password']) + ''' Store sudo password in a temp variable + because we will call _remove_sensitive_data() in + self.opt_manager.save_to_file() ''' + sudo_password = self.opt_manager.options['sudo_password'] + self.save_options() + shutdown_sys(sudo_password) else: self.finished_popup() self.open_destination_dir()