From 14bd744df666206ceac59e54371d6a1fbe022f54 Mon Sep 17 00:00:00 2001 From: Claudio Cambra Date: Thu, 15 Dec 2022 13:29:51 +0100 Subject: [PATCH] Use std::make_unique rather than manually build unique_ptr for oCSettings Signed-off-by: Claudio Cambra --- src/gui/accountmanager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/accountmanager.cpp b/src/gui/accountmanager.cpp index 32cb3abc3..00098bc86 100644 --- a/src/gui/accountmanager.cpp +++ b/src/gui/accountmanager.cpp @@ -177,7 +177,7 @@ bool AccountManager::restoreFromLegacySettings() qCInfo(lcAccountManager) << "Migrate: checking old config " << configFile; - std::unique_ptr oCSettings(new QSettings(configFile, QSettings::IniFormat)); + auto oCSettings = std::make_unique(configFile, QSettings::IniFormat); if (oCSettings->status() != QSettings::Status::NoError) { qCInfo(lcAccountManager) << "Error reading legacy configuration file" << oCSettings->status(); }