From 7129ad92a4ee5899680815c8cd2648a9f71bb651 Mon Sep 17 00:00:00 2001 From: jan Iversen Date: Sun, 9 Sep 2018 16:01:58 +0200 Subject: core/settings: optimize base_url functions. Remove unused variable and create of QString. Signed-off-by: Jan Iversen --- core/settings/qPrefCloudStorage.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'core/settings') diff --git a/core/settings/qPrefCloudStorage.cpp b/core/settings/qPrefCloudStorage.cpp index 741a14077..ef7605d97 100644 --- a/core/settings/qPrefCloudStorage.cpp +++ b/core/settings/qPrefCloudStorage.cpp @@ -28,12 +28,11 @@ void qPrefCloudStorage::loadSync(bool doSync) void qPrefCloudStorage::set_cloud_base_url(const QString &value) { - QString valueGit = value + "/git"; if (value != prefs.cloud_base_url) { // only free and set if not default if (prefs.cloud_base_url != default_prefs.cloud_base_url) { qPrefPrivate::copy_txt(&prefs.cloud_base_url, value); - qPrefPrivate::copy_txt(&prefs.cloud_git_url, QString(prefs.cloud_base_url) + "/git"); + qPrefPrivate::copy_txt(&prefs.cloud_git_url, value + "/git"); } disk_cloud_base_url(true); -- cgit v1.2.3-70-g09d2