BladeServiceProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 22
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 2 1
A boot() 0 5 1
1
<?php
2
3
namespace Mckenziearts\LaravelOAuth\Providers;
4
5
use Illuminate\Support\Facades\Blade;
6
use Illuminate\Support\ServiceProvider;
7
8
class BladeServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Bootstrap services.
12
     *
13
     * @return void
14
     */
15
    public function boot()
16
    {
17
        Blade::directive('socialite', function ($expression) {
18
            // Check user needs :login or :register text
19
            return "<?php echo LaravelSocialite::socialiteButtons($expression); ?>";
20
        });
21
    }
22
23
    /**
24
     * Register bindings in the container.
25
     *
26
     * @return void
27
     */
28
    public function register()
29
    {
30
        //
31
    }
32
}
33