aboutsummaryrefslogtreecommitdiffstats
path: root/include/opengraph.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/opengraph.php')
-rw-r--r--include/opengraph.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/opengraph.php b/include/opengraph.php
index 465acbd39..f62970c5d 100644
--- a/include/opengraph.php
+++ b/include/opengraph.php
@@ -21,7 +21,7 @@
$ogtitle = $item['title'];
// find first image if exist
- if(preg_match("/\[[zi]mg(=[0-9]+x[0-9]+)?\]([^\[]+)/is", $item['body'], $matches)) {
+ if (preg_match("/\[[zi]mg(=[0-9]+x[0-9]+)?\]([^\[]+)/is", $item['body'], $matches) || preg_match("/\[[zi]mg(=)([^\]]+)/is", $item['body'], $matches)) {
$ogimage = $matches[2];
$ogimagetype = guess_image_type($ogimage);
}