| Total Complexity | 4 |
| Total Lines | 26 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 1 | Features | 1 |
| 1 | <?php |
||
| 28 | class PHPInfoPage extends PageType { |
||
| 29 | |||
| 30 | public function getContent(): string { |
||
| 31 | if (isset($_REQUEST['no_design'])) { |
||
| 32 | phpinfo(); |
||
|
|
|||
| 33 | } else { |
||
| 34 | /*$content = ""; |
||
| 35 | |||
| 36 | ob_start(); |
||
| 37 | phpinfo(); |
||
| 38 | $content = ob_get_contents(); |
||
| 39 | ob_get_clean(); |
||
| 40 | |||
| 41 | return $content;*/ |
||
| 42 | |||
| 43 | //show iframe |
||
| 44 | return " <iframe src=\"" . DomainUtils::generateURL("admin/phpinfo") . "?no_design=true\"></iframe> "; |
||
| 45 | } |
||
| 46 | } |
||
| 47 | |||
| 48 | public function showDesign() { |
||
| 50 | } |
||
| 51 | |||
| 52 | public function listRequiredPermissions(): array { |
||
| 59 |
For hinted functions/methods where all return statements with the correct type are only reachable via conditions, ?null? gets implicitly returned which may be incompatible with the hinted type. Let?s take a look at an example: