Passed
Pull Request — master (#1470)
by
unknown
30:39
created

RefreshTokenTrait::getExpiryDateTime()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 1
c 0
b 0
f 0
nc 1
nop 0
dl 0
loc 3
ccs 2
cts 2
cp 1
crap 1
rs 10
1
<?php
2
3
/**
4
 * @author      Alex Bilbie <[email protected]>
5
 * @copyright   Copyright (c) Alex Bilbie
6
 * @license     http://mit-license.org/
7
 *
8
 * @link        https://github.com/thephpleague/oauth2-server
9
 */
10
11
declare(strict_types=1);
12
13
namespace League\OAuth2\Server\Entities\Traits;
14
15
use DateTimeImmutable;
16
use League\OAuth2\Server\Entities\AccessTokenEntityInterface;
17
18
trait RefreshTokenTrait
19
{
20
    protected AccessTokenEntityInterface $accessToken;
21
22
    /**
23
     * {@inheritdoc}
24
     */
25
    public function setAccessToken(AccessTokenEntityInterface $accessToken): void
26
    {
27 22
        $this->accessToken = $accessToken;
28
    }
29 22
30
    /**
31
     * {@inheritdoc}
32
     */
33
    public function getAccessToken(): AccessTokenEntityInterface
34
    {
35 1
        return $this->accessToken;
36
    }
37
}
38