Showing 573 of 5,122 total issues
Function index
has a Cognitive Complexity of 38 (exceeds 5 allowed). Consider refactoring. Open
function index(): void
{
global $xoopsDB, $myts, $desctext, $admin_lang;
$helper = Helper::getInstance();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method index
has 140 lines of code (exceeds 25 allowed). Consider refactoring. Open
function index(): void
{
global $xoopsDB, $myts, $desctext, $admin_lang;
$helper = Helper::getInstance();
Function modifyAds
has a Cognitive Complexity of 37 (exceeds 5 allowed). Consider refactoring. Open
function modifyAds($lid): void
{
global $xoopsDB, $xoopsModule, $myts, $desctext, $admin_lang;
$mytree = new Tree($xoopsDB->prefix('adslight_categories'), 'cid', 'pid');
$helper = Helper::getInstance();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method indexView
has 136 lines of code (exceeds 25 allowed). Consider refactoring. Open
function indexView($lid): void
{
global $xoopsDB, $xoopsModule, $myts, $desctext, $admin_lang;
$helper = Helper::getInstance();
$mytree = new Tree($xoopsDB->prefix('adslight_categories'), 'cid', 'pid');
Function listingDel
has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring. Open
function listingDel($lid, $ok): void
{
global $xoopsDB;
$helper = Helper::getInstance();
$sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method indexView
has 134 lines of code (exceeds 25 allowed). Consider refactoring. Open
function indexView($lid = null): void
{
global $xoopsDB, $myts, $desctext, $admin_lang;
$helper = Helper::getInstance();
$mytree = new Tree($xoopsDB->prefix('adslight_categories'), 'cid', 'pid');
Method index
has 132 lines of code (exceeds 25 allowed). Consider refactoring. Open
function index(): void
{
global $xoopsDB, $myts, $desctext;
$mytree = new Tree($xoopsDB->prefix('adslight_categories'), 'cid', 'pid');
Method adslight_seo_title
has 132 lines of code (exceeds 25 allowed). Consider refactoring. Open
function adslight_seo_title($title = '', $withExt = false)
{
/**
* if XOOPS ML is present, let's sanitize the title with the current language
*/
File modify_ads.php
has 386 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php declare(strict_types=1);
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
Function index
has a Cognitive Complexity of 35 (exceeds 5 allowed). Consider refactoring. Open
function index(): void
{
global $xoopsDB, $xoopsModule, $myts, $desctext, $admin_lang;
$helper = Helper::getInstance();
$mytree = new Tree($xoopsDB->prefix('adslight_categories'), 'cid', 'pid');
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function buildCache
has 129 lines of code (exceeds 25 allowed). Consider refactoring. Open
buildCache : function( c, callback, $tbodies ) {
var cache, val, txt, rowIndex, colIndex, tbodyIndex, $tbody, $row,
cols, $cells, cell, cacheTime, totalRows, rowData, prevRowData,
colMax, span, cacheIndex, hasParser, max, len, index,
table = c.table,
Function buildCache
has 129 lines of code (exceeds 25 allowed). Consider refactoring. Open
buildCache : function( c, callback, $tbodies ) {
var cache, val, txt, rowIndex, colIndex, tbodyIndex, $tbody, $row,
cols, $cells, cell, cacheTime, totalRows, rowData, prevRowData,
colMax, span, cacheIndex, hasParser, max, len, index,
table = c.table,
File viewcats.php
has 374 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php declare(strict_types=1);
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
Function initSort
has 124 lines of code (exceeds 25 allowed). Consider refactoring. Open
initSort : function( c, cell, event ) {
if ( c.table.isUpdating ) {
// let any updates complete before initializing a sort
return setTimeout( function() {
ts.initSort( c, cell, event );
Function initSort
has 124 lines of code (exceeds 25 allowed). Consider refactoring. Open
initSort : function( c, cell, event ) {
if ( c.table.isUpdating ) {
// let any updates complete before initializing a sort
return setTimeout( function() {
ts.initSort( c, cell, event );
File lightbox.js
has 373 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* Lightbox v2.11.3
* by Lokesh Dhakar
*
* More info:
Function defaultPrefilter
has 122 lines of code (exceeds 25 allowed). Consider refactoring. Open
function defaultPrefilter( elem, props, opts ) {
var prop, value, toggle, hooks, oldfire, propTween, restoreDisplay, display,
isBox = "width" in props || "height" in props,
anim = this,
orig = {},
Function Callbacks
has 121 lines of code (exceeds 25 allowed). Consider refactoring. Open
jQuery.Callbacks = function( options ) {
// Convert options from String-formatted to Object-formatted if needed
// (we check in cache first)
options = typeof options === "string" ?
Method getFormFeedback
has 120 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getFormFeedback($action = false): \XoopsThemeForm
{
if (!$action) {
$action = $_SERVER['REQUEST_URI'];
}
Function listBlocks
has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring. Open
public function listBlocks(): void
{
$pathIcon16 = Admin::iconUrl('', '16');
require_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"