@@ -54,7 +54,7 @@ |
||
| 54 | 54 | */ |
| 55 | 55 | public function getByDriver(string $driver): Collection |
| 56 | 56 | { |
| 57 | - return $this->channels->filter(function (array $channel) use ($driver) { |
|
| 57 | + return $this->channels->filter(function(array $channel) use ($driver) { |
|
| 58 | 58 | return $channel['driver'] === $driver; |
| 59 | 59 | }); |
| 60 | 60 | } |
@@ -34,7 +34,7 @@ |
||
| 34 | 34 | */ |
| 35 | 35 | public function initialize(Collection $parameters): DriverContract |
| 36 | 36 | { |
| 37 | - $parameters->each(function ($value, $key) { |
|
| 37 | + $parameters->each(function($value, $key) { |
|
| 38 | 38 | $key = Str::camel($key); |
| 39 | 39 | $this->$key = $value; |
| 40 | 40 | }); |
@@ -39,7 +39,7 @@ |
||
| 39 | 39 | */ |
| 40 | 40 | public function findDriver(string $name): ?array |
| 41 | 41 | { |
| 42 | - return $this->getDrivers()->first(function ($item) use ($name) { |
|
| 42 | + return $this->getDrivers()->first(function($item) use ($name) { |
|
| 43 | 43 | return $item['name'] === $name; |
| 44 | 44 | }); |
| 45 | 45 | } |
@@ -37,7 +37,7 @@ |
||
| 37 | 37 | // Install driver |
| 38 | 38 | $this->info('Installing driver...'); |
| 39 | 39 | |
| 40 | - $result = $composer->install($driver['package'], function ($_, $line) use (&$output) { |
|
| 40 | + $result = $composer->install($driver['package'], function($_, $line) use (&$output) { |
|
| 41 | 41 | $output .= $line; |
| 42 | 42 | }); |
| 43 | 43 | |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | */ |
| 66 | 66 | protected function registerConversationManager(): void |
| 67 | 67 | { |
| 68 | - $this->app->singleton(ConversationManagerContract::class, function () { |
|
| 68 | + $this->app->singleton(ConversationManagerContract::class, function() { |
|
| 69 | 69 | return new ConversationManager($this->app, $this->app[CacheRepository::class]); |
| 70 | 70 | }); |
| 71 | 71 | |
@@ -77,10 +77,10 @@ discard block |
||
| 77 | 77 | */ |
| 78 | 78 | protected function registerChannelManager(): void |
| 79 | 79 | { |
| 80 | - $this->app->singleton(ChannelManagerContract::class, function ($app) { |
|
| 81 | - return tap(new ChannelManager($app), function (ChannelManager $manager) { |
|
| 80 | + $this->app->singleton(ChannelManagerContract::class, function($app) { |
|
| 81 | + return tap(new ChannelManager($app), function(ChannelManager $manager) { |
|
| 82 | 82 | $channels = collect(config('fondbot.channels')) |
| 83 | - ->mapWithKeys(function (array $parameters, string $name) { |
|
| 83 | + ->mapWithKeys(function(array $parameters, string $name) { |
|
| 84 | 84 | return [$name => $parameters]; |
| 85 | 85 | }) |
| 86 | 86 | ->toArray(); |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | ->namespace('FondBot\Foundation\Http\Controllers') |
| 113 | 113 | ->as('fondbot.') |
| 114 | 114 | ->prefix('fondbot') |
| 115 | - ->group(function () { |
|
| 115 | + ->group(function() { |
|
| 116 | 116 | $this->loadRoutesFrom(__DIR__.'/../routes/webhooks.php'); |
| 117 | 117 | }); |
| 118 | 118 | } |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | $availableDrivers = $this->api->getDrivers(); |
| 33 | 33 | |
| 34 | 34 | $rows = collect($availableDrivers) |
| 35 | - ->transform(function ($item) use ($installedDrivers) { |
|
| 35 | + ->transform(function($item) use ($installedDrivers) { |
|
| 36 | 36 | return [ |
| 37 | 37 | $item['name'], |
| 38 | 38 | $item['package'], |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | public function handle(): void |
| 25 | 25 | { |
| 26 | 26 | $rows = collect($this->channelManager->all()) |
| 27 | - ->transform(function ($item, $name) { |
|
| 27 | + ->transform(function($item, $name) { |
|
| 28 | 28 | return [$name, $this->channelManager->driver($item['driver'])->getName(), $this->channelManager->create($name)->getWebhookUrl()]; |
| 29 | 29 | }) |
| 30 | 30 | ->toArray(); |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | public function handle(): void |
| 25 | 25 | { |
| 26 | 26 | $rows = collect($this->manager->getIntents()) |
| 27 | - ->transform(function ($item) { |
|
| 27 | + ->transform(function($item) { |
|
| 28 | 28 | return [$item]; |
| 29 | 29 | }) |
| 30 | 30 | ->toArray(); |