diff --git a/ymsgui.py b/ymsgui.py index 6b945e0..c054525 100755 --- a/ymsgui.py +++ b/ymsgui.py @@ -178,7 +178,7 @@ class Frontend: def on_destroy(self, widget, data=None): Gtk.main_quit() -def create_config(cfgfile): +def create_config(cfg, cfgfile): # create inital config file with open(cfgfile, 'w') as fh: fh.write('[DB]\n') @@ -207,7 +207,7 @@ if __name__ == "__main__": config = configparser.ConfigParser() cfgfile = os.path.expanduser(context.cfg['cfgfile']) if not config.read(cfgfile): - create_config(cfgfile) + create_config(context.cfg, cfgfile) gtkutils.messagebox( _("Configuration file '{}' not found.\n" "Default configuration has been created.\n"