Completed
Push — master ( 270f06...04fd8b )
by ARCANEDEV
12:31
created

ValidationServiceProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

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
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
    public function register()
23
    {
24
        //
25
    }
26
27
    /**
28
     * Boot the service provider.
29
     */
30
    public function boot()
31
    {
32
        /** @var \Illuminate\Validation\Factory $validator */
33
        $validator = $this->app['validator'];
34
35
        $validator->extend('currency_iso',       CurrencyValidator::class.'@validateCurrencyIso');
36
        $validator->extend('currency_supported', CurrencyValidator::class.'@validateCurrencySupported');
37
    }
38
}
39