Skip to content

Commit 64b2daa

Browse files
authored
Merge pull request #1044 from noplanman/1042-fix_animation_type
Return correct type for GIF message.
2 parents 607216b + cb61049 commit 64b2daa

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Exclamation symbols (:exclamation:) note something of importance e.g. breaking c
1212
### Removed
1313
### Fixed
1414
- Execution of `/start` command without any custom implementation.
15+
- Return `animation` type for GIF Message (which returns both `animation` and `document`).
1516
### Security
1617

1718
## [0.61.1] - 2019-11-23

src/Entities/Animation.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,5 +29,13 @@
2929
**/
3030
class Animation extends Entity
3131
{
32-
32+
/**
33+
* {@inheritdoc}
34+
*/
35+
protected function subEntities()
36+
{
37+
return [
38+
'thumb' => PhotoSize::class,
39+
];
40+
}
3341
}

src/Entities/Message.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,8 +206,8 @@ public function getType()
206206
$types = [
207207
'text',
208208
'audio',
209-
'document',
210209
'animation',
210+
'document',
211211
'game',
212212
'photo',
213213
'sticker',

0 commit comments

Comments
 (0)