Passed
Push — master ( ffee1f...e53f62 )
by Samuel
03:34
created

InvalidCredentialsException::setUserEmail()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
ccs 0
cts 2
cp 0
rs 10
cc 1
nc 1
nop 1
crap 2
1
<?php
2
3
namespace App\Domain\Authentication\Exception;
4
5
class InvalidCredentialsException extends AuthenticationException
6
{
7
    // Voluntarily not more information
8
    private string $userEmail;
9
10
    // Invalid credentials asserted in LoginSubmitActionTest
11 2
    public function __construct(string $email, string $message = 'Invalid credentials')
12
    {
13 2
        parent::__construct($message);
14 2
        $this->userEmail = $email;
15
    }
16
17
    /**
18
     * @return string
19
     */
20 2
    public function getUserEmail(): string
21
    {
22 2
        return $this->userEmail;
23
    }
24
}
25