User::__construct()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 10
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 10
ccs 0
cts 7
cp 0
rs 9.4285
cc 2
eloc 5
nc 2
nop 2
crap 6
1
<?php
2
/**
3
 * @author Stefano Torresi (http://stefanotorresi.it)
4
 * @license See the file LICENSE.txt for copying permission.
5
 * ************************************************
6
 */
7
8
namespace Thorr\OAuth2\Entity;
9
10
use Thorr\Persistence\Entity\AbstractEntity;
11
12
class User extends AbstractEntity implements ThirdPartyAwareUserInterface
13
{
14
    use UserTrait;
15
    use ThirdPartyAwareTrait;
16
17
    public function __construct($uuid = null, $password = null)
18
    {
19
        parent::__construct($uuid);
20
21
        if ($password) {
22
            $this->setPassword($password);
23
        }
24
25
        $this->initThirdPartyCredentials();
26
    }
27
}
28