This commit is contained in:
Daniil Gentili 2021-08-14 16:10:04 +02:00
parent b25d8033e2
commit 2c60ddf413
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7

View File

@ -497,7 +497,7 @@ function internalDecode(string $fileId): array
fixLong($result, 'access_hash'); fixLong($result, 'access_hash');
if ($result['typeId'] <= PHOTO) { if ($result['typeId'] <= PHOTO) {
$parsePhotoSize = function () use (&$result, &$fileId): void { $parsePhotoSize = function () use (&$result, &$fileId) {
$result['photosize_source'] = $result['subVersion'] >= 4 ? \unpack('V', \stream_get_contents($fileId, 4))[1] : 0; $result['photosize_source'] = $result['subVersion'] >= 4 ? \unpack('V', \stream_get_contents($fileId, 4))[1] : 0;
switch ($result['photosize_source']) { switch ($result['photosize_source']) {
case PHOTOSIZE_SOURCE_LEGACY: case PHOTOSIZE_SOURCE_LEGACY: