Passed
Push — master ( e83847...16b30f )
by Radu
01:36
created

OutputLoader::cli()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
1
<?php
2
namespace ParcelValue\ApiClient;
3
4
use WebServCo\Framework\Framework;
5
6
final class OutputLoader extends \WebServCo\Framework\AbstractOutputLoader
7
{
8
    public function __construct($projectPath)
9
    {
10
        parent::__construct(
11
            $projectPath,
12
            Framework::library('HtmlOutput'),
13
            Framework::library('JsonOutput')
14
        );
15
    }
16
17
    public function html($data, $template)
18
    {
19
        return parent::html($data, $template);
20
    }
21
22
    public function htmlPage($data, $pageTemplate, $mainTemplate = null)
23
    {
24
        return parent::htmlPage($data, $pageTemplate, $mainTemplate);
25
    }
26
27
    public function json($data)
28
    {
29
        return parent::json($data);
30
    }
31
32
    public function cli($string, $eol = true)
33
    {
34
        return parent::cli($string, $eol);
0 ignored issues
show
Bug introduced by
Are you sure the usage of parent::cli($string, $eol) targeting WebServCo\Framework\AbstractOutputLoader::cli() seems to always return null.

This check looks for function or method calls that always return null and whose return value is used.

class A
{
    function getObject()
    {
        return null;
    }

}

$a = new A();
if ($a->getObject()) {

The method getObject() can return nothing but null, so it makes no sense to use the return value.

The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.

Loading history...
35
    }
36
}
37