Skip to content

Commit

Permalink
Load settings only when server starts
Browse files Browse the repository at this point in the history
  • Loading branch information
hluk committed Dec 21, 2016
1 parent 894ab91 commit 58985b9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 2 additions & 1 deletion src/app/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,8 @@ void App::restoreSettings(bool canModifySettings)
{
m_app->setProperty("CopyQ_server", canModifySettings);

createPlatformNativeInterface()->loadSettings();
if (canModifySettings)
createPlatformNativeInterface()->loadSettings();

Settings::restore();

Expand Down
6 changes: 1 addition & 5 deletions src/platform/win/winplatform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -271,11 +271,7 @@ QCoreApplication *WinPlatform::createClientApplication(int &argc, char **argv)

void WinPlatform::loadSettings()
{
static bool migrated = false;
if (!migrated) {
migrateConfigToAppDir();
migrated = true;
}
migrateConfigToAppDir();
}

PlatformClipboardPtr WinPlatform::clipboard()
Expand Down

0 comments on commit 58985b9

Please sign in to comment.