Test Failed
Push — master ( 6db55f...0b650e )
by Chris
21:02
created

ReCaptchaServiceProvider   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 4
eloc 5
c 0
b 0
f 0
dl 0
loc 20
rs 10

4 Methods

Rating   Name   Duplication   Size   Complexity  
A factory() 0 3 1
A id() 0 3 1
A args() 0 3 1
A types() 0 3 1
1
<?php
2
3
namespace Leonidas\Framework\Site\Provider\League;
4
5
use Leonidas\Framework\Provider\League\Abstracts\AbstractLeagueServiceFactory;
6
use Leonidas\Framework\Site\Provider\ReCaptchaProvider;
7
use Panamax\Contracts\ServiceFactoryInterface;
8
use ReCaptcha\ReCaptcha;
9
10
class ReCaptchaServiceProvider extends AbstractLeagueServiceFactory
11
{
12
    protected function id(): string
13
    {
14
        return 'reCaptcha';
15
    }
16
17
    protected function types(): array
18
    {
19
        return [ReCaptcha::class];
20
    }
21
22
    protected function factory(): ServiceFactoryInterface
23
    {
24
        return new ReCaptchaProvider();
25
    }
26
27
    protected function args(): ?array
28
    {
29
        return $this->getConfig('services.recaptcha.secret');
30
    }
31
}
32