Take reference to folder in folder map within User::getFolder

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2024-10-16 10:10:54 +08:00 committed by backportbot[bot]
parent 4dd7ca30e3
commit c48c1c2680

View file

@ -913,7 +913,7 @@ void User::setCurrentUser(const bool &isCurrent)
Folder *User::getFolder() const
{
for (Folder *const folder : FolderMan::instance()->map()) {
for (const auto &folder : FolderMan::instance()->map()) {
if (folder->accountState() == _account.data()) {
return folder;
}