Code Duplication    Length = 5-5 lines in 2 locations

admin/ajax.php 1 location

@@ 57-61 (lines=5) @@
54
        $instrid = Request::getInt('instrid', 0, 'POST');
55
56
        // Проверка
57
        if (!$GLOBALS['xoopsSecurity']->check()) {
58
            $err         = true;
59
            $err_txt     = implode(', ', $GLOBALS['xoopsSecurity']->getErrors());
60
            $message_err .= $err_txt . '<br>' . _AM_INSTR_TRY_AGAIN . '<br>';
61
        }
62
        // =========================
63
        // Устанавливаем новый token
64
        $token_name    = 'XOOPS_TOKEN';

admin/instr.php 1 location

@@ 403-407 (lines=5) @@
400
        $message_err = '';
401
402
        // Проверка сессии
403
        if (!$GLOBALS['xoopsSecurity']->check()) {
404
            $err         = true;
405
            $err_txt     = implode(', ', $GLOBALS['xoopsSecurity']->getErrors());
406
            $message_err .= $err_txt . '<br>';
407
        }
408
409
        // Если мы редактируем
410
        if ($pageid) {