TransactionServiceProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

Changes 2
Bugs 0 Features 1
Metric Value
eloc 6
c 2
b 0
f 1
dl 0
loc 24
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 3 1
A boot() 0 7 1
1
<?php
2
3
namespace Dizatech\Transaction;
4
5
use Dizatech\Transaction\Core\TransactionManager;
6
use Dizatech\Transaction\Facades\Transaction;
7
use Illuminate\Support\ServiceProvider;
8
9
class TransactionServiceProvider extends ServiceProvider
10
{
11
    /**
12
     * Register services.
13
     *
14
     * @return void
15
     */
16
    public function register()
17
    {
18
        Transaction::shouldProxyTo(TransactionManager::class);
19
    }
20
21
    /**
22
     * Bootstrap services.
23
     *
24
     * @return void
25
     */
26
    public function boot()
27
    {
28
        $this->loadMigrationsFrom(__DIR__ . '/database/migrations');
29
30
        $this->publishes([
31
            __DIR__.'/config/dizatech_transaction.php' =>config_path('dizatech_transaction.php')
32
        ], 'dizatech_transaction');
33
    }
34
}
35