| Conditions | 2 |
| Paths | 2 |
| Total Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | public function __construct() { |
||
| 15 | global $ID; |
||
| 16 | parent::__construct(); |
||
| 17 | |||
| 18 | $parent = tpl_getparent($ID); |
||
| 19 | if(!$parent) { |
||
|
|
|||
| 20 | throw new \RuntimeException("No parent for back action"); |
||
| 21 | } |
||
| 22 | |||
| 23 | $this->id = $parent; |
||
| 24 | $this->params = array('do' => ''); |
||
| 25 | $this->accesskey = 'b'; |
||
| 26 | $this->svg = DOKU_INC . 'lib/images/menu/12-back_arrow-left.svg'; |
||
| 27 | } |
||
| 28 | |||
| 30 |
In PHP, under loose comparison (like
==, or!=, orswitchconditions), values of different types might be equal.For
stringvalues, the empty string''is a special case, in particular the following results might be unexpected: