Completed
Push — master ( 121042...c79028 )
by Mr
05:32
created

ServiceProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 7
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace OpenVPN\Laravel;
4
5
use Illuminate\Support\ServiceProvider as BaseServiceProvider;
6
7
class ServiceProvider extends BaseServiceProvider
8
{
9
    /**
10
     * Bootstrap any application services.
11
     *
12
     * @return void
13
     */
14
    public function boot(): void
15
    {
16
        $this->publishes([
17
            __DIR__ . '/../../configs/openvpn-client.php' => config_path('openvpn-client.php'),
18
            __DIR__ . '/../../configs/openvpn-server.php' => config_path('openvpn-server.php'),
19
        ]);
20
    }
21
22
    /**
23
     * Register any application services.
24
     *
25
     * @return void
26
     */
27
    public function register(): void
28
    {
29
        $this->mergeConfigFrom(
30
            __DIR__ . '/../../configs/openvpn-client.php', 'openvpn-client'
31
        );
32
33
        $this->mergeConfigFrom(
34
            __DIR__ . '/../../configs/openvpn-server.php', 'openvpn-server'
35
        );
36
37
        $this->app->bind(ConfigWrapper::class);
38
    }
39
}
40