Completed
Push — master ( d43e16...e4687b )
by Владислав
02:15
created

Socialink   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 1
cbo 1
dl 0
loc 23
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A init() 0 18 1
1
<?php
2
3
namespace jumper423\decaptcha\services;
4
5
/**
6
 * Class Socialink.
7
 */
8
class Socialink extends RuCaptcha
9
{
10
    protected $host = 'socialink.ru';
11
12
    public function init()
13
    {
14
        parent::init();
15
        unset(
16
            $this->paramsNames[self::ACTION_FIELD_QUESTION],
17
            $this->paramsNames[self::ACTION_FIELD_TEXTINSTRUCTIONS],
18
            $this->paramsNames[self::ACTION_FIELD_PINGBACK],
19
            $this->actions[static::ACTION_RECOGNIZE][static::ACTION_FIELDS][self::ACTION_FIELD_QUESTION],
20
            $this->actions[static::ACTION_RECOGNIZE][static::ACTION_FIELDS][self::ACTION_FIELD_TEXTINSTRUCTIONS],
21
            $this->actions[static::ACTION_RECOGNIZE][static::ACTION_FIELDS][self::ACTION_FIELD_PINGBACK]
22
        );
23
        $this->paramsNames[self::ACTION_FIELD_IS_RUSSIAN] = 'is_russian';
24
        $this->actions[static::ACTION_RECOGNIZE][static::ACTION_FIELDS][static::ACTION_FIELD_IS_RUSSIAN] = [
25
            static::PARAM_SLUG_DEFAULT => 0,
26
            static::PARAM_SLUG_TYPE    => static::PARAM_FIELD_TYPE_INTEGER,
27
        ];
28
        $this->actions[static::ACTION_RECOGNIZE][static::ACTION_FIELDS][self::ACTION_FIELD_SOFT_ID][self::PARAM_SLUG_DEFAULT] = 0;
29
    }
30
}
31