Conditions | 2 |
Paths | 2 |
Total Lines | 18 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 0 |
1 | <?php |
||
16 | public function fetch($filename) |
||
17 | { |
||
18 | $contents = @file_get_contents($this->baseUrl.'/'.$filename); |
||
19 | |||
20 | if (false === $contents) { |
||
21 | return serialize(array( |
||
22 | 'result' => false, |
||
23 | 'errors' => array( |
||
24 | array( |
||
25 | 'no' => 0, |
||
26 | 'str' => 'file_get_contents call failed', |
||
27 | ), |
||
28 | ), |
||
29 | )); |
||
30 | } |
||
31 | |||
32 | return $contents; |
||
33 | } |
||
34 | } |
||
35 |