]> git.mxchange.org Git - friendica.git/commitdiff
Fix warning: E_WARNING: Undefined array key "publish"
authorMichael <heluecht@pirati.ca>
Wed, 10 Jan 2024 22:04:02 +0000 (22:04 +0000)
committerRoland Häder <roland@mxchange.org>
Sun, 28 Jan 2024 15:37:43 +0000 (16:37 +0100)
src/Module/Settings/Channels.php

index 1d8e7f8133c3c9994dcb3766ca44f89825a6c955..d846a91be733d085b146f3de48b8aabebd49c73b 100644 (file)
@@ -114,7 +114,7 @@ class Channels extends BaseSettings
                                'full-text-search' => $request['text_search'][$id],
                                'media-type'       => ($request['image'][$id] ? 1 : 0) | ($request['video'][$id] ? 2 : 0) | ($request['audio'][$id] ? 4 : 0),
                                'languages'        => $request['languages'][$id],
-                               'publish'          => $request['publish'][$id],
+                               'publish'          => $request['publish'][$id] ?? false,
                        ]);
                        $saved = $this->channel->save($channel);
                        $this->logger->debug('Save channel', ['id' => $id, 'saved' => $saved]);