[GTK3] Fix config default_load_path keyerror

This commit is contained in:
hugosenari 2018-09-14 15:06:17 +01:00 committed by Calum Lind
parent 250afa6e0b
commit ae0b072b75
1 changed files with 4 additions and 1 deletions

View File

@ -675,7 +675,10 @@ class AddTorrentDialog(component.Component):
# Load the 'default_load_path' from the config # Load the 'default_load_path' from the config
self.config = ConfigManager('gtk3ui.conf') self.config = ConfigManager('gtk3ui.conf')
if self.config['default_load_path'] is not None: if (
'default_load_path' in self.config
and self.config['default_load_path'] is not None
):
chooser.set_current_folder(self.config['default_load_path']) chooser.set_current_folder(self.config['default_load_path'])
# Run the dialog # Run the dialog