XoopsModules25x/about

View on GitHub
admin/admin.page.php

Summary

Maintainability
A
45 mins
Test Coverage

Avoid deeply nested control flow statements.
Open

                    if ($pageObj->getVar('page_image')) {
                        @unlink($upload_path . '/' . $pageObj->getVar('page_image'));
                    }
Severity: Major
Found in admin/admin.page.php - About 45 mins to fix

    There must be a single space after the USE keyword
    Open

    use  Xmf\Module\Admin;
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    There must be one blank line after the last USE statement; 0 found;
    Open

    use XoopsModules\About\PageHandler;
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    Line exceeds 120 characters; contains 206 characters
    Open

                xoops_confirm(['ok' => Constants::CONFIRM_OK, 'id' => $pageObj->getVar('page_id'), 'op' => 'delete'], $_SERVER['REQUEST_URI'], sprintf(_AM_ABOUT_RUSUREDEL, $pageObj->getVar('page_menu_title')));
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    Line exceeds 120 characters; contains 142 characters
    Open

                $helper->redirect('admin/admin.page.php', Constants::REDIRECT_DELAY_MEDIUM, implode(',', $GLOBALS['xoopsSecurity']->getErrors()));
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    Line exceeds 120 characters; contains 136 characters
    Open

                $uploader          = new \XoopsMediaUploader($upload_path, $allowed_mimetypes, $maxfilesize, $maxfilewidth, $maxfileheight);
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    Line exceeds 120 characters; contains 144 characters
    Open

                $helper->redirect('admin/admin.page.php', Constants::REDIRECT_DELAY_MEDIUM, sprintf(_AM_ABOUT_SAVEDSUCCESS, _AM_ABOUT_PAGE_INSERT));
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    Line exceeds 120 characters; contains 124 characters
    Open

                        $helper->redirect('admin/admin.page.php', Constants::REDIRECT_DELAY_MEDIUM, _AM_ABOUT_PAGE_ORDER_ERROR);
    Severity: Minor
    Found in admin/admin.page.php by phpcodesniffer

    There are no issues that match your filters.

    Category
    Status