Showing 540 of 47,256 total issues
Method b_system_admin_warnings_show
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
Function Enumerable
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
var Enumerable = (function() {
function each(iterator, context) {
try {
this._each(iterator, context);
} catch (e) {
- 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 TCGenerateMac
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
function TCGenerateMac() {
var s = '';
var c = 0,n = 1;
var r,g,b;
for (j = 0; j < 15; j ++) {
- 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 protector_onuninstall_base
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
function protector_onuninstall_base($module, $mydirname) {
// transations on module uninstall
global $ret; // TODO :-D
if (!is_array($ret)) $ret = array ();
- 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 imanager_addcat
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
function imanager_addcat() {
if (!icms::$security->check()) {
redirect_header('admin.php?fct=images', 3, implode('<br />', icms::$security->getErrors()));
}
- 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 matcherFromGroupMatchers
has 68 lines of code (exceeds 25 allowed). Consider refactoring. Open
function matcherFromGroupMatchers( elementMatchers, setMatchers ) {
var bySet = setMatchers.length > 0,
byElement = elementMatchers.length > 0,
superMatcher = function( seed, context, xml, results, outermost ) {
var elem, j, matcher,
Function setMatcher
has 66 lines of code (exceeds 25 allowed). Consider refactoring. Open
function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {
if ( postFilter && !postFilter[ expando ] ) {
postFilter = setMatcher( postFilter );
}
if ( postFinder && !postFinder[ expando ] ) {
File users.php
has 276 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
// $Id: users.php 12313 2013-09-15 21:14:35Z skenow $
// ------------------------------------------------------------------------ //
// XOOPS - PHP Content Management System //
// Copyright (c) 2000 XOOPS.org //
Function xoops_module_deactivate
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
function xoops_module_deactivate($mid) {
global $icms_page_handler, $icms_block_handler, $icmsConfig, $icmsAdminTpl;
if (!isset($icms_page_handler)) {
$icms_page_handler = icms_getModuleHandler('pages', 'system');
}
- 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 adminNav
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
function adminNav($id = NULL, $separador = "/", $list = FALSE, $style = "style='font-weight:bold'") {
global $target, $type;
$admin_url = 'browser.php?target=' . $target . '&type=' . $type;
if ($id === FALSE) {
- 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 adminNav
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
function adminNav($id = NULL, $separador = "/", $list = FALSE, $style = "style='font-weight:bold'") {
$admin_url = ICMS_MODULES_URL . "/system/admin.php?fct=images";
if ($id === FALSE) {
return FALSE;
} else {
- 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 imanager_addcat
has 64 lines of code (exceeds 25 allowed). Consider refactoring. Open
function imanager_addcat() {
/* because we're using a function, the GET/POST variables are not in scope */
global $imgcat_pid, $imgcat_name, $imgcat_maxsize;
global $imgcat_maxwidth, $imgcat_maxheight, $imgcat_display;
global $imgcat_weight, $imgcat_storetype, $imgcat_foldername;
File main.php
has 272 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
// $Id: main.php 12313 2013-09-15 21:14:35Z skenow $
// ------------------------------------------------------------------------ //
// XOOPS - PHP Content Management System //
// Copyright (c) 2000 XOOPS.org //
Function Class
has 63 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Class = (function() {
var IS_DONTENUM_BUGGY = (function(){
for (var p in { toString: 1 }) {
if (p === 'toString') return false;
Method protector_onupdate_base
has 62 lines of code (exceeds 25 allowed). Consider refactoring. Open
function protector_onupdate_base($module, $mydirname) {
// transations on module update
global $msgs; // TODO :-D
if (!is_array($msgs)) $msgs = array ();
Method imanager_addfile
has 62 lines of code (exceeds 25 allowed). Consider refactoring. Open
function imanager_addfile() {
if (!icms::$security->check()) {
redirect_header('admin.php?fct=images', 3, implode('<br />', icms::$security->getErrors()));
}
Method imanager_addfile
has 62 lines of code (exceeds 25 allowed). Consider refactoring. Open
function imanager_addfile() {
/* because we are using a function, the GET/POST variables are not in scope */
global $imgcat_id, $image_display, $image_weight, $image_nicename;
if (!icms::$security->check()) {
Function superMatcher
has 61 lines of code (exceeds 25 allowed). Consider refactoring. Open
superMatcher = function( seed, context, xml, results, outermost ) {
var elem, j, matcher,
matchedCount = 0,
i = "0",
unmatched = seed && [],
Method queryFromFile
has 61 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function queryFromFile($sql_file_path) {
$tables = array();
if (!file_exists($sql_file_path)) {
return false;
Function xoopsCodeText
has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring. Open
function xoopsCodeText(id, hiddentext, enterTextboxPhrase){
var textareaDom = xoopsGetElementById(id);
var textDom = xoopsGetElementById(id + "Addtext");
var fontDom = xoopsGetElementById(id + "Font");
var colorDom = xoopsGetElementById(id + "Color");
- 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"