From 0d415fb3c9db41ee97b7ce933ebc84eab38a1fa4 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Sun, 7 Jan 2018 02:34:37 -0800 Subject: hubzilla issue #946 --- include/feedutils.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/feedutils.php b/include/feedutils.php index 4638ef66a..5e48cb1ee 100644 --- a/include/feedutils.php +++ b/include/feedutils.php @@ -1801,12 +1801,17 @@ function compat_photos_list($s) { if($found) { foreach($matches as $match) { - $ret[] = [ + $entry = [ 'href' => $match[2], - 'length' => 0, 'type' => guess_image_type($match[2]) ]; + $sizer = new \Zotlabs\Lib\Img_filesize($match[2]); + $size = $sizer->getSize(); + if(intval($size)) { + $entry['length'] = intval($size); + } + $ret[] = $entry; } } -- cgit v1.2.3