Skip to content
Snippets Groups Projects
Unverified Commit 0f911e2d authored by Julius Härtl's avatar Julius Härtl
Browse files

Add default values when parsing account data


Signed-off-by: default avatarJulius Härtl <jus@bitgrid.net>
parent f5286bcb
No related branches found
No related tags found
No related merge requests found
...@@ -330,7 +330,7 @@ class AccountManager implements IAccountManager { ...@@ -330,7 +330,7 @@ class AccountManager implements IAccountManager {
private function parseAccountData(IUser $user, $data): Account { private function parseAccountData(IUser $user, $data): Account {
$account = new Account($user); $account = new Account($user);
foreach($data as $property => $accountData) { 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; return $account;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment