summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2018-12-24 14:18:32 +0100
committerGitHub <noreply@github.com>2018-12-24 14:18:32 +0100
commit39131eee3e118dc8139981d2270af02f4141bfc4 (patch)
treea62a24409f022afeae6f2eb5c6d5e577edb2a3fa
parent73e0b7d8e6334e0a6601aed8abbcfdf133ac579d (diff)
parent0f911e2d13bc227308e4970a3ecf259b98ea9276 (diff)
downloadnextcloud-server-39131eee3e118dc8139981d2270af02f4141bfc4.tar.gz
nextcloud-server-39131eee3e118dc8139981d2270af02f4141bfc4.zip
Merge pull request #13240 from nextcloud/bugfix/noid/accountmanager-defaults
Add default values when parsing account data
-rw-r--r--lib/private/Accounts/AccountManager.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Accounts/AccountManager.php b/lib/private/Accounts/AccountManager.php
index a057cb4fc27..408f070dc0d 100644
--- a/lib/private/Accounts/AccountManager.php
+++ b/lib/private/Accounts/AccountManager.php
@@ -330,7 +330,7 @@ class AccountManager implements IAccountManager {
private function parseAccountData(IUser $user, $data): Account {
$account = new Account($user);
foreach($data as $property => $accountData) {
- $account->setProperty($property, $accountData['value'] ?? '', $accountData['scope'], $accountData['verified']);
+ $account->setProperty($property, $accountData['value'] ?? '', $accountData['scope'] ?? self::VISIBILITY_PRIVATE, $accountData['verified'] ?? self::NOT_VERIFIED);
}
return $account;
}