Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2020-09-29 19:32:48 +0300
committerHarald Eilertsen <haraldei@anduin.net>2020-09-29 20:32:24 +0300
commit061ef027ff89641bcdecf4bc559c38089b33a62b (patch)
tree4a4c4194a2ccd71bd5a8205b7b685642efcc378c /src/gui/accountstate.cpp
parent074a94ceb9ac84b42acd63b7418e542181f75466 (diff)
Don't hold ref to value returned from function.
Signed-off-by: Harald Eilertsen <haraldei@anduin.net>
Diffstat (limited to 'src/gui/accountstate.cpp')
-rw-r--r--src/gui/accountstate.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/accountstate.cpp b/src/gui/accountstate.cpp
index be8b90876..58a679031 100644
--- a/src/gui/accountstate.cpp
+++ b/src/gui/accountstate.cpp
@@ -441,7 +441,7 @@ void AccountState::slotNavigationAppsFetched(const QJsonDocument &reply, int sta
if(!reply.isEmpty()){
auto element = reply.object().value("ocs").toObject().value("data");
- const auto &navLinks = element.toArray();
+ const auto navLinks = element.toArray();
if(navLinks.size() > 0){
for (const QJsonValue &value : navLinks) {
@@ -468,7 +468,7 @@ AccountAppList AccountState::appList() const
AccountApp* AccountState::findApp(const QString &appId) const
{
if(!appId.isEmpty()) {
- const auto &apps = appList();
+ const auto apps = appList();
const auto it = std::find_if(apps.cbegin(), apps.cend(), [appId](const auto &app) {
return app->id() == appId;
});