Skip to content

Commit

Permalink
Merge pull request #1 from niladam/feature/allow-laravel-11
Browse files Browse the repository at this point in the history
  • Loading branch information
niladam authored May 1, 2024
2 parents b55242c + 84f5d93 commit c84873e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
],
"require": {
"php": "^8.1",
"illuminate/http": "^8.0|^9.0|^10.0"
"illuminate/http": "^8.0|^9.0|^10.0|^11.0"
},
"autoload": {
"psr-4": {
Expand Down
13 changes: 8 additions & 5 deletions src/LaravelSendsmsServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,19 @@

class LaravelSendsmsServiceProvider extends ServiceProvider
{
public function register()
public function register(): void
{
$this->app->singleton(
LaravelSendsms::class,
fn() => new LaravelSendsms(config("laravel-sendsms"))
abstract: LaravelSendsms::class,
concrete: fn() => new LaravelSendsms(config("laravel-sendsms"))
);

$this->app->bind("laravel-sendsms", LaravelSendsms::class);

$this->app->singleton("command.sendsms", fn() => new LaravelSendsmsCommand());
$this->app->singleton(
"command.sendsms",
fn() => new LaravelSendsmsCommand()
);

$this->commands(["command.sendsms"]);
}
Expand All @@ -26,7 +29,7 @@ public function boot()
if ($this->app->runningInConsole()) {
$this->publishes(
[
__DIR__."/../config/sendsms.php" => config_path(
__DIR__ . "/../config/sendsms.php" => config_path(
"laravel-sendsms.php"
),
],
Expand Down

0 comments on commit c84873e

Please sign in to comment.