aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2024-12-10 11:20:45 +0100
committerJoas Schilling <coding@schilljs.com>2024-12-10 11:20:45 +0100
commit280b4929191981d3f10ece95575a7981cdfc0ae4 (patch)
tree7b4ee621f1642057c49043fad70967877fcab90f /lib
parent5af0d137e7ba016488e3717e28d698fda195dc24 (diff)
downloadnextcloud-server-280b4929191981d3f10ece95575a7981cdfc0ae4.tar.gz
nextcloud-server-280b4929191981d3f10ece95575a7981cdfc0ae4.zip
fix(federation): Allow Oracles empty stringsbugfix/noid/oracle-federation
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/unstable/Security/Signature/Model/Signatory.php12
1 files changed, 9 insertions, 3 deletions
diff --git a/lib/unstable/Security/Signature/Model/Signatory.php b/lib/unstable/Security/Signature/Model/Signatory.php
index c3a275082ae..6bd50bb1098 100644
--- a/lib/unstable/Security/Signature/Model/Signatory.php
+++ b/lib/unstable/Security/Signature/Model/Signatory.php
@@ -39,8 +39,7 @@ use OCP\AppFramework\Db\Entity;
* @method void setType(int $type)
* @method int getStatus()
* @method void setStatus(int $status)
- * @method void setAccount(string $account)
- * @method string getAccount()
+ * @method void setAccount(?string $account)
* @method void setMetadata(array $metadata)
* @method ?array getMetadata()
* @method void setCreation(int $creation)
@@ -56,7 +55,7 @@ class Signatory extends Entity implements JsonSerializable {
protected string $host = '';
protected string $publicKey = '';
protected string $privateKey = '';
- protected string $account = '';
+ protected ?string $account = '';
protected int $type = 9;
protected int $status = 1;
protected ?array $metadata = null;
@@ -146,6 +145,13 @@ class Signatory extends Entity implements JsonSerializable {
}
/**
+ * @experimental 31.0.0
+ */
+ public function getAccount(): string {
+ return $this->account ?? '';
+ }
+
+ /**
* update an entry in metadata
*
* @param string $key