Test Failed
Pull Request — master (#97)
by Gildonei
03:38
created

FirstUpperCase   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
eloc 3
dl 0
loc 5
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A toView() 0 3 2
1
<?php
2
3
namespace Ubiquity\contents\transformation\transformers;
4
5
use Ubiquity\contents\transformation\TransformerViewInterface;
6
7
/**
8
 * Make a string first character uppercase.
9
 * Ubiquity\contents\transformation\transformers$FirstUpperCase
10
 * This class is part of Ubiquity
11
 *
12
 * @author jcheron <[email protected]>
13
 * @version 1.0.0
14
 * @since 2.1.1
15
 */
16
class FirstUpperCase implements TransformerViewInterface {
17
18 3
	public static function toView($value) {
19 3
		if ($value != null)
20 3
			return ucfirst ( $value );
21
	}
22
}
23