mirror of
https://github.com/friendica/friendica
synced 2025-04-29 14:24:22 +02:00
Fix PR 14591 - improve blurhash creation
This commit is contained in:
parent
9a8554e40a
commit
17c335238f
6 changed files with 20 additions and 19 deletions
|
@ -130,12 +130,12 @@ class Link
|
|||
|
||||
if (Images::isSupportedMimeType($fields['mimetype'])) {
|
||||
$img_str = $curlResult->getBodyString();
|
||||
$image = new Image($img_str, $fields['mimetype'], $url);
|
||||
$image = new Image($img_str, $fields['mimetype'], $url, false);
|
||||
if ($image->isValid()) {
|
||||
$fields['mimetype'] = $image->getType();
|
||||
$fields['width'] = $image->getWidth();
|
||||
$fields['height'] = $image->getHeight();
|
||||
$fields['blurhash'] = $image->getBlurHash();
|
||||
$fields['blurhash'] = $image->getBlurHash($img_str);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue