Code Duplication    Length = 12-12 lines in 2 locations

class.AuthProvider.php 1 location

@@ 58-69 (lines=12) @@
55
     *
56
     * @return Auth\Authenticator|false The specified Authenticator class instance or false if it is not loaded
57
     */
58
    public function getAuthenticator($methodName)
59
    {
60
        $count = count($this->methods);
61
        for($i = 0; $i < $count; $i++)
62
        {
63
            if(strcasecmp(get_class($this->methods[$i]), $methodName) === 0)
64
            {
65
                return $this->methods[$i];
66
            }
67
        }
68
        return false;
69
    }
70
71
    /**
72
     * Get the Auth\User class instance for the specified login

class.EmailProvider.php 1 location

@@ 59-70 (lines=12) @@
56
     *
57
     * @return false|\Email\EmailService The Email service specified or false if it is not found
58
     */
59
    public function getEmailMethod($methodName)
60
    {
61
        $count = count($this->methods);
62
        for($i = 0; $i < $count; $i++)
63
        {
64
            if(strcasecmp(get_class($this->methods[$i]), $methodName) === 0)
65
            {
66
                return $this->methods[$i];
67
            }
68
        }
69
        return false;
70
    }
71
72
    /**
73
     * Send the email