GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 2f0bc6...b62162 )
by Marius
04:15
created

PlainTextView::fetch()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 9
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 2.032

Importance

Changes 0
Metric Value
cc 2
eloc 6
nc 2
nop 1
dl 0
loc 9
ccs 4
cts 5
cp 0.8
crap 2.032
rs 9.6666
c 0
b 0
f 0
1
<?php
2
/**
3
 * @package presentation
4
 * @subpackage views
5
 * @author marius orcsik <[email protected]>
6
 * @date 2011.02.17
7
 */
8
namespace vsc\presentation\views;
9
10
use vsc\domain\models\StaticFileModel;
11
12
class PlainTextView extends ViewA implements ViewInterface {
13
	protected $sContentType = 'text/plain';
14
	protected $sFolder = 'txt';
0 ignored issues
show
Coding Style introduced by
Equals sign not aligned with surrounding assignments; expected 6 spaces but found 1 space

This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.

To visualize

$a = "a";
$ab = "ab";
$abc = "abc";

will produce issues in the first and second line, while this second example

$a   = "a";
$ab  = "ab";
$abc = "abc";

will produce no issues.

Loading history...
15
16 1
	public function fetch($includePath) {
0 ignored issues
show
Documentation introduced by
The return type could not be reliably inferred; please add a @return annotation.

Our type inference engine in quite powerful, but sometimes the code does not provide enough clues to go by. In these cases we request you to add a @return annotation as described here.

Loading history...
17 1
		$oModel = $this->getModel();
18
		/* @var StaticFileModel $oModel */
19 1
		if (StaticFileModel::isValid($oModel)) {
20
			return $oModel->getFileContent();
21
		} else {
22 1
			return parent::fetch($includePath);
23
		}
24
	}
25
}
26