load the Settings in onionshare/__init__.py later, so that when saving slug, the private_key/hidservauth string have already been saved by the Onion object

This commit is contained in:
Miguel Jacq 2018-01-18 08:14:36 +11:00
parent 4261670b59
commit 9ed748db86
No known key found for this signature in database
GPG Key ID: EEA4341C6D97A0B6

View File

@ -79,7 +79,6 @@ def main(cwd=None):
settings = Settings(config)
settings.load()
# Start the Onion object
onion = Onion()
@ -129,6 +128,7 @@ def main(cwd=None):
app.shutdown_timer.start()
# Save the web slug if we are using a persistent private key
settings.load()
if settings.get('save_private_key'):
if not settings.get('slug'):
settings.set('slug', web.slug)