Conditions | 3 |
Paths | 3 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 3 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
36 | 5 | public function render() |
|
37 | { |
||
38 | 5 | if (false === $this->configuration->isEnabled()) { |
|
39 | 1 | return $this->arguments['imageUrl']; |
|
40 | } |
||
41 | |||
42 | 4 | $url = '//' . $this->configuration->getHost() . '/' . $this->arguments['imageUrl']; |
|
43 | |||
44 | 4 | if ($this->hasUrlParameters()) { |
|
45 | 3 | $url .= '?' . http_build_query($this->getUrlParameters()); |
|
46 | 3 | } |
|
47 | |||
48 | 4 | return $url; |
|
49 | } |
||
50 | |||
71 |