<?php
/**
- * @copyright Copyright (C) 2010-2023, the Friendica project
+ * @copyright Copyright (C) 2010-2024, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
$filesize = strlen($img_str);
try {
- $data = (array)@getimagesizefromstring($img_str);
+ $data = @getimagesizefromstring($img_str);
} catch (\Exception $e) {
return [];
}
- if (empty($data)) {
+ if (!$data) {
return [];
}