diff options
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/Accounts/Account.php | 4 | ||||
-rw-r--r-- | lib/private/Accounts/AccountProperty.php | 17 |
2 files changed, 17 insertions, 4 deletions
diff --git a/lib/private/Accounts/Account.php b/lib/private/Accounts/Account.php index e7aeb6fa1e9..109691641fd 100644 --- a/lib/private/Accounts/Account.php +++ b/lib/private/Accounts/Account.php @@ -44,8 +44,8 @@ class Account implements IAccount { $this->user = $user; } - public function setProperty(string $property, string $value, string $scope, string $verified): IAccount { - $this->properties[$property] = new AccountProperty($property, $value, $scope, $verified); + public function setProperty(string $property, string $value, string $scope, string $verified, string $verificationData = ''): IAccount { + $this->properties[$property] = new AccountProperty($property, $value, $scope, $verified, $verificationData); return $this; } diff --git a/lib/private/Accounts/AccountProperty.php b/lib/private/Accounts/AccountProperty.php index 0152137f6de..cb60a7c6940 100644 --- a/lib/private/Accounts/AccountProperty.php +++ b/lib/private/Accounts/AccountProperty.php @@ -39,12 +39,15 @@ class AccountProperty implements IAccountProperty { private $scope; /** @var string */ private $verified; + /** @var string */ + private $verificationData; - public function __construct(string $name, string $value, string $scope, string $verified) { + public function __construct(string $name, string $value, string $scope, string $verified, string $verificationData) { $this->name = $name; $this->value = $value; $this->setScope($scope); $this->verified = $verified; + $this->verificationData = $verificationData; } public function jsonSerialize() { @@ -52,7 +55,8 @@ class AccountProperty implements IAccountProperty { 'name' => $this->getName(), 'value' => $this->getValue(), 'scope' => $this->getScope(), - 'verified' => $this->getVerified() + 'verified' => $this->getVerified(), + 'verificationData' => $this->getVerificationData(), ]; } @@ -164,4 +168,13 @@ class AccountProperty implements IAccountProperty { public function getVerified(): string { return $this->verified; } + + public function setVerificationData(string $verificationData): IAccountProperty { + $this->verificationData = $verificationData; + return $this; + } + + public function getVerificationData(): string { + return $this->verificationData; + } } |