]> git.mxchange.org Git - friendica.git/commitdiff
Avoid a notice
authorMichael <heluecht@pirati.ca>
Mon, 5 Aug 2019 16:48:58 +0000 (16:48 +0000)
committerMichael <heluecht@pirati.ca>
Mon, 5 Aug 2019 16:48:58 +0000 (16:48 +0000)
src/Content/Text/BBCode.php

index 668d6e6236da5e11926939b1cfb6c66cd617dbb2..a5cb78727cf8ad0d97ea82dfe711d5afb1a8ce4a 100644 (file)
@@ -246,7 +246,7 @@ class BBCode extends BaseObject
                                        $post['images'][] = ['url' => str_replace('-1.', '-0.', $picture[1]), 'description' => $picture[2]];
                                }
                        }
-                       if (!empty($post['images'][0]['description'])) {
+                       if (!empty($post['images']) && !empty($post['images'][0]['description'])) {
                                $post['image_description'] = $post['images'][0]['description'];
                        }
                }