Showing 374 of 649 total issues
Function parseTokens
has a Cognitive Complexity of 247 (exceeds 5 allowed). Consider refactoring. Open
function parseTokens(pf, ar) {
var v, mode = -1, par = (pf != 'ol_');
var fnMark = (par && !ar.length ? 1 : 0);
for (i = 0; i < ar.length; i++) {
if (mode < 0) {
- 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 parseTokens
has a Cognitive Complexity of 247 (exceeds 5 allowed). Consider refactoring. Open
function parseTokens(pf, ar) {
// What the next argument is expected to be.
var v, mode = -1, par = (pf != 'ol_');
var fnMark = (par && !ar.length ? 1 : 0);
- 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
File overlib.js
has 1174 lines of code (exceeds 250 allowed). Consider refactoring. Open
//\/////
//\ overLIB 4.05 - You may not remove or change this notice.
//\ Copyright Erik Bosrup 1998-2004. All rights reserved.
//\
//\ Contributors are listed on the homepage.
File overlib_mini.js
has 1168 lines of code (exceeds 250 allowed). Consider refactoring. Open
//\/////
//\ overLIB 4.05 - You may not remove or change this notice.
//\ Copyright Erik Bosrup 1998-2004. All rights reserved.
//\
//\ Contributors are listed on the homepage.
Function scroll_placeLayer
has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring. Open
function scroll_placeLayer() {
var placeX, placeY, widthFix = 0;
var hasAnchor = (typeof o3_anchor != 'undefined' && o3_anchor);
// HORIZONTAL PLACEMENT
- 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 scroll_placeLayer
has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring. Open
function scroll_placeLayer() {
var placeX, placeY, widthFix = 0;
var hasAnchor = (typeof o3_anchor != 'undefined' && o3_anchor);
if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
- 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 anchorPlaceLayer
has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring. Open
function anchorPlaceLayer() {
var placeX, placeY, widthFix = 0;
if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
} else if (typeof(o3_frame.innerWidth) == 'number') {
- 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 anchorPlaceLayer
has a Cognitive Complexity of 125 (exceeds 5 allowed). Consider refactoring. Open
function anchorPlaceLayer() {
var placeX, placeY, widthFix = 0;
// HORIZONTAL PLACEMENT
if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth == 'number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
- 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
File xoops_version.php
has 930 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php declare(strict_types=1);
/**
* Module: SmartFAQ
* Author: The SmartFactory <www.smartfactory.ca>
File FaqHandler.php
has 738 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php declare(strict_types=1);
namespace XoopsModules\Smartfaq;
/**
Function placeLayer
has a Cognitive Complexity of 85 (exceeds 5 allowed). Consider refactoring. Open
function placeLayer() {
var placeX, placeY, widthFix = 0;
// HORIZONTAL PLACEMENT
if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
- 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 placeLayer
has a Cognitive Complexity of 85 (exceeds 5 allowed). Consider refactoring. Open
function placeLayer() {
var placeX, placeY, widthFix = 0;
if (eval('o3_frame.' + docRoot) && eval("typeof o3_frame." + docRoot + ".clientWidth=='number'") && eval('o3_frame.' + docRoot + '.clientWidth')) {
iwidth = eval('o3_frame.' + docRoot + '.clientWidth');
} else if (typeof(o3_frame.innerWidth) == 'number') {
- 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 parseTokens
has 282 lines of code (exceeds 25 allowed). Consider refactoring. Open
function parseTokens(pf, ar) {
// What the next argument is expected to be.
var v, mode = -1, par = (pf != 'ol_');
var fnMark = (par && !ar.length ? 1 : 0);
Function parseTokens
has 282 lines of code (exceeds 25 allowed). Consider refactoring. Open
function parseTokens(pf, ar) {
var v, mode = -1, par = (pf != 'ol_');
var fnMark = (par && !ar.length ? 1 : 0);
for (i = 0; i < ar.length; i++) {
if (mode < 0) {
File Blocksadmin.php
has 611 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
declare(strict_types=1);
namespace XoopsModules\Smartfaq\Common;
Function reOrder
has a Cognitive Complexity of 61 (exceeds 5 allowed). Consider refactoring. Open
function reOrder(hookPt, fnRef, order) {
if (!order || typeof order == 'undefined' || typeof order == 'number') return;
var newPt = new Array(), match;
if (typeof order == 'function') {
if (typeof fnRef == 'object') {
- 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 reOrder
has a Cognitive Complexity of 61 (exceeds 5 allowed). Consider refactoring. Open
function reOrder(hookPt, fnRef, order) {
if (!order || typeof order == 'undefined' || typeof order == 'number') return;
var newPt = new Array(), match;
- 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 listBlocks
has 229 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function listBlocks()
: void
{
global $xoopsModule, $pathIcon16;
require_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
Function getAnchorOffsets
has a Cognitive Complexity of 56 (exceeds 5 allowed). Consider refactoring. Open
function getAnchorOffsets(mkObj) {
var fx = fy = 0, mp, puc, mkAry, sx = sy = 0, w = o3_anchoralign
var mW = mH = pW = pH = 0
var off = [0, 0]
mkAry = w.split(',');
- 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 generateShadow
has a Cognitive Complexity of 56 (exceeds 5 allowed). Consider refactoring. Open
function generateShadow(content) {
var wd, ht, X = 0, Y = 0, zIdx = 0, txt, dpObj, puObj, bS = '', aPos, posStr = new Array();
if (!o3_shadow || (o3_shadowx == 0 && o3_shadowy == 0)) return;
X = Math.abs(o3_shadowx);
Y = Math.abs(o3_shadowy);
- 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"