| Conditions | 4 |
| Paths | 3 |
| Total Lines | 21 |
| Code Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 30 | function newbbWelcome() |
||
| 31 | { |
||
| 32 | global $forumObject; |
||
| 33 | $ret = ''; |
||
| 34 | |||
| 35 | $forumId = @$GLOBALS['xoopsModuleConfig']['welcome_forum']; |
||
| 36 | if (!$forumId) { |
||
| 37 | return false; |
||
| 38 | } |
||
| 39 | $forumHandler = Helper::getInstance()->getHandler('Forum'); |
||
| 40 | $forumObject = $forumHandler->get($forumId); |
||
| 41 | if (!$forumObject || !$forumHandler->getPermission($forumObject)) { |
||
|
|
|||
| 42 | unset($forumObject); |
||
| 43 | |||
| 44 | return false; |
||
| 45 | } |
||
| 46 | |||
| 47 | require_once __DIR__ . '/functions.welcome.inc.php'; |
||
| 48 | unset($forumObject); |
||
| 49 | |||
| 50 | return $ret; |
||
| 51 | } |
||
| 55 |