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.

WithLocales::getLocale()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 0
loc 4
ccs 2
cts 2
cp 1
crap 1
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace RafaHernandez\LaravelIntl\Concerns;
4
5
trait WithLocales
6
{
7
    /**
8
     * The current locale.
9
     *
10
     * @var string $locale
11
     */
12
    protected $locale;
13
14
    /**
15
     * The current locale.
16
     *
17
     * @var string $locale
18
     */
19
    protected $fallbackLocale;
20
21
    /**
22
     * Get the current locale.
23
     *
24
     * @return string
25
     */
26 105
    public function getLocale()
27
    {
28 105
        return $this->locale;
29
    }
30
31
    /**
32
     * Set the current locale.
33
     *
34
     * @param $locale
35
     * @return $this
36
     */
37 105
    public function setLocale($locale)
38
    {
39 105
        $this->locale = $locale;
40
41 105
        return $this;
42
    }
43
44
    /**
45
     * Get the fallback locale.
46
     *
47
     * @return string
48
     */
49 93
    public function getFallbackLocale()
50
    {
51 93
        return $this->fallbackLocale;
52
    }
53
54
    /**
55
     * Set the fallback locale.
56
     *
57
     * @param $locale
58
     * @return $this
59
     */
60 105
    public function setFallbackLocale($locale)
61
    {
62 105
        $this->fallbackLocale = $locale;
63
64 105
        return $this;
65
    }
66
}
67