ThreemaGateway_Helper_UserField   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A verifyThreemaId() 0 9 1
1
<?php
2
/**
3
 * User field helper.
4
 *
5
 * @package ThreemaGateway
6
 * @author rugk
7
 * @copyright Copyright (c) 2016 rugk
8
 * @license MIT
9
*/
10
11
/**
12
 * Verifies user fields.
13
 */
14
class ThreemaGateway_Helper_UserField
15
{
16
    /**
17
     * Checks the custom Threema ID user field.
18
     *
19
     * This basically only passes the request to
20
     * ThreemaGateway_Handler_Verification->checkThreemaId().
21
     *
22
     * @param  string $field The field id
23
     * @param  string $value The entered value
24
     * @param  mixed  $error
25
     * @return bool
26
     */
27
    public static function verifyThreemaId($field, &$value, &$error)
0 ignored issues
show
Unused Code introduced by
The parameter $field is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
28
    {
29
        /** @var XenForo_Options $options */
30
        $options = XenForo_Application::getOptions();
31
32
        return ThreemaGateway_Handler_Validation::checkThreemaId(
33
            $value, 'personal', $error, $options->threema_gateway_userfield_verifyexist
34
        );
35
    }
36
}
37