Skip to content

Commit 5e5c130

Browse files
authored
Merge pull request #913 from noplanman/911-fix_message_type
Return correct message type
2 parents 5bec182 + ebb4d23 commit 5e5c130

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ Exclamation symbols (:exclamation:) note something of importance e.g. breaking c
99
### Deprecated
1010
### Removed
1111
### Fixed
12+
- Return correct message type.
1213
### Security
1314

1415
## [0.55.0] - 2018-12-20

src/Entities/Message.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ public function getType()
313313

314314
$is_command = strlen($this->getCommand()) > 0;
315315
foreach ($types as $type) {
316-
if ($this->getProperty($type)) {
316+
if ($this->getProperty($type) !== null) {
317317
if ($is_command && $type === 'text') {
318318
return 'command';
319319
}

0 commit comments

Comments
 (0)