Skip to content

Commit

Permalink
Support for laravel 5.6
Browse files Browse the repository at this point in the history
  • Loading branch information
vigneshgurusamy committed Mar 30, 2018
1 parent 5b7dacc commit 2f4c6f0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
}
],
"require": {
"php": ">=7.0.0",
"illuminate/support": "5.3.*|5.4.*|5.5.*",
"php": ">=7.1.3",
"illuminate/support": "5.3.*|5.4.*|5.5.*|5.6.*",
"guzzlehttp/guzzle": "~6.0"
},
"autoload": {
Expand All @@ -31,7 +31,7 @@
},
"require-dev": {
"orchestra/testbench": "~3.5",
"phpunit/phpunit": "~6.0"
"phpunit/phpunit": "~6.0|~7.0"
},
"autoload-dev": {
"psr-4": {
Expand Down
11 changes: 6 additions & 5 deletions src/SmsManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,10 +128,9 @@ public function dispatch(): ResponseInterface
*/
public function send(Device $device, string $message): ResponseInterface
{
$this->device = $device;
$this->message = $message;

return $this->dispatch();
return $this->to($device)
->message($message)
->dispatch();
}

/**
Expand Down Expand Up @@ -165,7 +164,9 @@ public function resolveConnection(Device $device): string
}
}

return $connection ?: AdapterException::noPossibleConnection($device);
return isset($connection)
? $connection
: AdapterException::noPossibleConnection($device);
}

/**
Expand Down

0 comments on commit 2f4c6f0

Please sign in to comment.