Showing 4,334 of 7,873 total issues
Function gd_info
has a Cognitive Complexity of 62 (exceeds 5 allowed). Consider refactoring. Open
function gd_info() {
static $gd_info = array();
if (empty($gd_info)) {
// based on code by johnschaefer at gmx dot de
// from PHP help on gd_info()
- 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 smarty_internal_testinstall.php
has 571 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Smarty Internal TestInstall
* Test Smarty installation
*
Function getContainerList
has a Cognitive Complexity of 61 (exceeds 5 allowed). Consider refactoring. Open
public function getContainerList($path) {
$properties = $this->getPropertyList();
$list = $this->getS3ObjectList($path);
$editAction = $this->getEditActionId();
- 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 setup
has a Cognitive Complexity of 60 (exceeds 5 allowed). Consider refactoring. Open
setup: function() {
var ddTarget = this.config.target;
var ddTargetEl = this.config.targetEl;
var cfg = this.config;
- 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 wrapText
has a Cognitive Complexity of 60 (exceeds 5 allowed). Consider refactoring. Open
public function wrapText($message, $length, $qp_mode = false)
{
if ($qp_mode) {
$soft_break = sprintf(' =%s', static::$LE);
} 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
File moduser.class.php
has 559 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* This file is part of MODX Revolution.
*
* Copyright (c) MODX, LLC. All Rights Reserved.
File Smarty.class.php
has 558 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Project: Smarty: the PHP compiling template engine
* File: Smarty.class.php
*
File modx.tree.element.js
has 556 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* Generates the Element Tree
*
* @class MODx.tree.Element
* @extends MODx.tree.Tree
File smarty_internal_configfilelexer.php
has 554 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Smarty Internal Plugin Configfilelexer
*
* This is the lexer to break the config file source into tokens
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
Function serve
has a Cognitive Complexity of 59 (exceeds 5 allowed). Consider refactoring. Open
public static function serve($controller, $options = array())
{
if (! self::$isDocRootSet && 0 === stripos(PHP_OS, 'win')) {
self::setDocRoot();
}
- 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 read
has a Cognitive Complexity of 59 (exceeds 5 allowed). Consider refactoring. Open
public function read(array $options = array()) {
$this->__kill = false;
$messages = array();
$topicMessages = array();
$msgLimit = isset($options['msg_limit']) ? intval($options['msg_limit']) : 5;
- 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 default.inc.php
has 552 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 552 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en
File default.inc.php
has 552 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* Default English lexicon topic
*
* @language en