Completed
Pull Request — master (#6)
by ARCANEDEV
09:01
created

ValidationServiceProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 5
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 8
ccs 5
cts 5
cp 1
crap 1
rs 9.4285
1
<?php namespace Arcanedev\Currencies\Validators;
2
3
use Arcanedev\Support\ServiceProvider;
4
5
/**
6
 * Class     ValidationServiceProvider
7
 *
8
 * @package  Arcanedev\Currencies\Providers
9
 * @author   ARCANEDEV <[email protected]>
10
 */
11
class ValidationServiceProvider extends ServiceProvider
12
{
13
    /* ------------------------------------------------------------------------------------------------
14
     |  Main Functions
15
     | ------------------------------------------------------------------------------------------------
16
     */
17
    /**
18
     * Register the service provider.
19
     *
20
     * @return void
21
     */
22 444
    public function register()
23
    {
24
        //
25 444
    }
26
27
    /**
28
     * Boot the service provider.
29
     */
30 444
    public function boot()
31
    {
32
        /** @var \Illuminate\Validation\Factory $validator */
33 444
        $validator = $this->app['validator'];
34
35 444
        $validator->extend('currency_iso',       CurrencyValidator::class.'@validateCurrencyIso');
36 444
        $validator->extend('currency_supported', CurrencyValidator::class.'@validateCurrencySupported');
37 444
    }
38
}
39