Test Failed
Pull Request — master (#122)
by
unknown
30:03 queued 23:05
created

FallbackDetector::get()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 2
dl 0
loc 4
ccs 0
cts 2
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Thinktomorrow\Locale\Detectors;
4
5
use Thinktomorrow\Locale\Scope;
6
use Thinktomorrow\Locale\Values\Config;
7
use Thinktomorrow\Locale\Values\Locale;
8
9
class FallbackDetector implements Detector
10
{
11
    public function get(Scope $scope, Config $config): ?Locale
12
    {
13
        return Locale::from(app()->getLocale());
14
    }
15
}
16