Completed
Push — master ( 72613d...069c91 )
by Michael
02:16
created

header.php (1 issue)

Severity

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
include __DIR__ . '/../../mainfile.php';
4
$moduleDirName = basename(__DIR__);
5
require_once __DIR__ . '/include/common.php';
6
7
require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
8
9
require_once __DIR__ . '/class/utility.php';
10
11
$myts = MyTextSanitizer::getInstance();
12
13
if (false !== ($moduleHelper = Xmf\Module\Helper::getHelper($moduleDirName))) {
0 ignored issues
show
This if statement is empty and can be removed.

This check looks for the bodies of if statements that have no statements or where all statements have been commented out. This may be the result of changes for debugging or the code may simply be obsolete.

These if bodies can be removed. If you have an empty if but statements in the else branch, consider inverting the condition.

if (rand(1, 6) > 3) {
//print "Check failed";
} else {
    print "Check succeeded";
}

could be turned into

if (rand(1, 6) <= 3) {
    print "Check succeeded";
}

This is much more concise to read.

Loading history...
14
} else {
15
    $moduleHelper = Xmf\Module\Helper::getHelper('system');
16
}
17
18
$moduleHelper->loadLanguage('main');
19
20
//------------------------------------------------------
21
// Getting eXtCal object's handler
22
//$catHandler        = xoops_getModuleHandler(_EXTCAL_CLS_CAT, _EXTCAL_MODULE);
23
//$eventHandler      = xoops_getModuleHandler(_EXTCAL_CLS_EVENT, _EXTCAL_MODULE);
24
//$extcalTimeHandler = ExtcalTime::getHandler();
25
//$permHandler       = ExtcalPerm::getHandler();
26
//$GLOBALS['xoopsUser']         = $GLOBALS['xoopsUser'] ?: null;
27
//------------------------------------------------------
28