Skip to content

Commit 72819f6

Browse files
committed
Merge pull request barryvdh#19 from GrahamCampbell/registration
Moved command registration to the boot method
2 parents ef3e7a1 + 5bb7e9b commit 72819f6

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/AsyncServiceProvider.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ class AsyncServiceProvider extends ServiceProvider
2222
*/
2323
public function boot()
2424
{
25-
$manager = $this->app['queue'];
26-
$this->registerAsyncConnector($manager);
25+
$this->registerAsyncConnector($this->app['queue']);
26+
27+
$this->commands('command.queue.async');
2728
}
2829

2930
/**
@@ -48,8 +49,6 @@ protected function registerAsyncCommand($app)
4849
$app['command.queue.async'] = $app->share(function ($app) {
4950
return new AsyncCommand();
5051
});
51-
52-
$this->commands('command.queue.async');
5352
}
5453

5554
/**

0 commit comments

Comments
 (0)