Skip to content

Commit

Permalink
Merge pull request #1739 from nextcloud/backport/1736/stable29
Browse files Browse the repository at this point in the history
[stable29] fix toArray on null
  • Loading branch information
ArtificialOwl authored Nov 1, 2024
2 parents 41a39c4 + 65ebcd5 commit 1949c16
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Model/ShareWrapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,7 @@ public function jsonSerialize(): array {
'shareType' => $this->getShareType(),
'providerId' => $this->getProviderId(),
'permissions' => $this->getPermissions(),
'attributes' => json_encode($this->getAttributes()->toArray()),
'attributes' => ($this->getAttributes() !== null) ? json_encode($this->getAttributes()->toArray()) : null,
'hideDownload' => $this->getHideDownload(),
'itemType' => $this->getItemType(),
'itemSource' => $this->getItemSource(),
Expand Down

0 comments on commit 1949c16

Please sign in to comment.