Total Complexity | 2 |
Total Lines | 22 |
Duplicated Lines | 0 % |
Coverage | 77.78% |
Changes | 0 |
1 | <?php |
||
11 | final class ElasticSearchServiceProvider extends ServiceProvider |
||
12 | { |
||
13 | /** |
||
14 | * {@inheritdoc} |
||
15 | */ |
||
16 | 33 | public function register(): void |
|
17 | { |
||
18 | $this->app->bind(Client::class, function () { |
||
19 | 24 | return ClientBuilder::create()->setHosts([config('elasticsearch.host')])->build(); |
|
20 | 33 | }); |
|
21 | |||
22 | 33 | $this->publishes([ |
|
23 | 33 | __DIR__.'/../config/elasticsearch.php' => config_path('elasticsearch.php'), |
|
24 | 33 | ], 'config'); |
|
25 | 33 | } |
|
26 | |||
27 | /** |
||
28 | * {@inheritdoc} |
||
29 | */ |
||
30 | public function provides(): array |
||
33 | } |
||
34 | } |
||
35 |