Skip to content

Commit 16d9922

Browse files
authored
Merge pull request #2 from inDeev/handleStringChannel
Allowed channel to be integer as string
2 parents 9a90089 + c45f3f0 commit 16d9922

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/GoSMS/GoSMS.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ public function setMessage($message)
327327
*/
328328
public function setChannel($channel)
329329
{
330-
if ( ! is_int($channel) || ( $channel < 0 ) ) {
330+
if ( ! strval(intval($channel)) == $channel || ( $channel < 0 ) ) {
331331
throw new GoSMSException\InvalidChannel('Invalid channel');
332332
}
333333

0 commit comments

Comments
 (0)