StyleMinifier   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 4
c 1
b 0
f 0
dl 0
loc 18
ccs 3
cts 3
cp 1
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A minify() 0 5 1
1
<?php
2
3
namespace Staticka\Filters;
4
5
/**
6
 * Style Minifier
7
 *
8
 * @package Staticka
9
 * @author  Rougin Gutib <[email protected]>
10
 */
11
class StyleMinifier extends InlineMinifier
12
{
13
    /**
14
     * @var string
15
     */
16
    protected $tagname = 'style';
17
18
    /**
19
     * Minifies the specified code.
20
     *
21
     * @param  string $code
22
     * @return string
23
     */
24 3
    protected function minify($code)
25
    {
26 3
        $minified = (string) parent::minify($code);
27
28 3
        return str_replace(' > ', '>', $minified);
29
    }
30
}
31