Completed
Pull Request — master (#132)
by
unknown
02:04
created

CaptchaController   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
dl 0
loc 16
rs 10
c 0
b 0
f 0
wmc 1
lcom 0
cbo 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A getCaptcha() 0 4 1
1
<?php
2
3
namespace Heimuya\Captcha;
4
5
use Illuminate\Routing\Controller;
6
use Illuminate\Config\Repository;
7
8
/**
9
 * Class CaptchaController
10
 * @package Heimuya\Captcha
11
 */
12
class CaptchaController extends Controller
13
{
14
15
    /**
16
     * get CAPTCHA
17
     *
18
     * @param \Heimuya\Captcha\Captcha $captcha
19
     * @param string $config
20
     * @return \Intervention\Image\ImageManager->response
0 ignored issues
show
Documentation introduced by
The doc-type \Intervention\Image\ImageManager->response could not be parsed: Expected "|" or "end of type", but got ">" at position 33. (view supported doc-types)

This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.

Loading history...
21
     */
22
    public function getCaptcha(Captcha $captcha, $config = 'default')
23
    {
24
        return $captcha->create($config)->response(config(['captcha.' . $config . '.type' => 'png']), config(['captcha.' . $config . 'quality' => 90]));
25
    }
26
27
}
28