GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

OAuth2::getClient()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 1
b 0
f 1
1
<?php
2
3
namespace Milkmeowo\Framework\Dingo\Auth\Providers;
4
5
use Dingo\Api\Auth\Provider\OAuth2 as DingoOAuth2;
6
7
class OAuth2 extends DingoOAuth2
8
{
9
    /**
10
     * @return \League\OAuth2\Server\ResourceServer
11
     */
12
    public function getResource()
13
    {
14
        return $this->resource;
15
    }
16
17
    /**
18
     * @return \League\OAuth2\Server\Entity\AccessTokenEntity
19
     */
20
    public function getAccessToken()
21
    {
22
        return $this->resource->getAccessToken();
23
    }
24
25
    /**
26
     * @return \League\OAuth2\Server\Entity\SessionEntity
27
     */
28
    public function getSession()
29
    {
30
        return $this->getAccessToken()->getSession();
31
    }
32
33
    /**
34
     * Get the resource owner ID of the current request.
35
     *
36
     * @return string
37
     */
38
    public function getResourceOwnerId()
39
    {
40
        return $this->getSession()->getOwnerId();
41
    }
42
43
    /**
44
     * Get the resource owner type of the current request (client or user).
45
     *
46
     * @return string
47
     */
48
    public function getResourceOwnerType()
49
    {
50
        return $this->getSession()->getOwnerType();
51
    }
52
53
    /**
54
     * Get the client of the current request.
55
     *
56
     * @return \League\OAuth2\Server\Entity\ClientEntity
57
     */
58
    public function getClient()
59
    {
60
        return $this->getSession()->getClient();
61
    }
62
63
    /**
64
     * Get the client id of the current request.
65
     *
66
     * @return string
67
     */
68
    public function getClientId()
69
    {
70
        return $this->getClient()->getId();
71
    }
72
}
73