Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/polls.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Db/Share.php')
-rw-r--r--lib/Db/Share.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/Db/Share.php b/lib/Db/Share.php
index 153857eb..864cafef 100644
--- a/lib/Db/Share.php
+++ b/lib/Db/Share.php
@@ -221,8 +221,12 @@ class Share extends Entity implements JsonSerializable {
$this->setMiscSettings(json_encode($value));
}
- private function getMiscSettingsArray() : ?array {
- return json_decode($this->getMiscSettings(), true);
+ private function getMiscSettingsArray() : array {
+ if ($this->getMiscSettings()) {
+ return json_decode($this->getMiscSettings(), true);
+ }
+
+ return [];
}
/**