FallbackLocaleResolver   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 12
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A resolve() 0 3 1
1
<?php
2
declare(strict_types=1);
3
4
namespace Nexendrie\Translation\Resolvers;
5
6
/**
7
 * FallbackLocaleResolver
8
 * Fallback resolver when nothing else can be used
9
 * Uses just default language (specified by loader)
10
 *
11
 * @author Jakub Konečný
12
 */
13 1
class FallbackLocaleResolver implements ILocaleResolver {
14 1
  use \Nette\SmartObject;
15
  
16
  /**
17
   * Resolve language
18
   *
19
   * @return NULL
20
   */
21
  public function resolve(): ?string {
0 ignored issues
show
Coding Style introduced by Jakub Konečný
Expected 1 space after closing parenthesis; found 0
Loading history...
Coding Style introduced by Jakub Konečný
Inline shorthand IF statement must be declared on a single line
Loading history...
22 1
    return NULL;
23
  }
24
}
25
?>