bkdotcom/PHPDebugConsole

Showing 161 of 181 total issues

    public function bindParam($parameter, &$variable, $dataType = PdoBase::PARAM_STR,$length = null, $driverOptions = null) Found in src/Debug/Collector/Pdo/Statement.php - About 35 mins to fix Function logSessionVals has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function logSessionVals($sessionNamePassed)
{
$namePrev = null; if (\session_status() !== PHP_SESSION_ACTIVE) { if ($sessionNamePassed === null) {
Found in src/Debug/Plugin/LogEnv.php - About 35 mins to fix

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"

Function sort has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open

    public function sort(&$array,$order = 'visibility')
{
if (!$array) { return; } Found in src/Debug/Abstraction/AbstractObjectHelper.php - About 35 mins to fix 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 logListeners has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function logListeners($eventName)
{
$listeners =$this->eventDispatcher->getListeners($eventName); foreach ($listeners as $i =>$listener) {
if (!($listener instanceof \Closure)) { Found in src/Debug/Framework/Laravel/EventsSubscriber.php - About 35 mins to fix 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 reduceDataSummary has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function reduceDataSummary() { /* Remove non-essential summary entries */ Found in src/Debug/Route/ChromeLogger.php - About 35 mins to fix 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 isSkippable has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private static function isSkippable($frame, $levelMax) {$frame = \array_merge(array(
'class' => null,
'function' => null,
Found in src/Backtrace/SkipInternal.php - About 35 mins to fix

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"

$.fn.debugEnhance = function (method, arg1, arg2) { // console.warn('debugEnhance', method, this) if (method === 'sidebar') { debugEnhanceSidebar(this, arg1) } else if (method === 'buildChannelList') { Found in src/Debug/js_src/main.js - About 35 mins to fix 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 visToggles has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open function visToggles ($inner, accessible) {
var flags = {
hasProtected: $inner.children('.protected').not('.magic, .magic-read, .magic-write').length > 0, hasPrivate:$inner.children('.private').not('.magic, .magic-read, .magic-write').length > 0,
hasExcluded: $inner.children('.debuginfo-excluded').hide().length > 0, Found in src/Debug/js_src/enhanceObject.js - About 35 mins to fix 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 expand has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open export function expand ($node) {
var icon = config.iconsExpand.collapse
var isToggle = $node.is('[data-toggle]') var what = isToggle ?$node.data('toggle')
Found in src/Debug/js_src/expandCollapse.js - About 35 mins to fix

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"

    public function onStart(Abstraction $abs) {$obj = $abs->getSubject(); if ($obj instanceof \DateTime || $obj instanceof \DateTimeImmutable) { // check for both DateTime and DateTimeImmutable Found in src/Debug/Abstraction/AbstractObject.php - About 35 mins to fix 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 dumpEncodedUpdateVals has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function dumpEncodedUpdateVals($vals, Abstraction $abs) { switch ($abs['typeMore']) {
case Abstracter::TYPE_STRING_BASE64:
$vals['labelDecoded'] = 'decoded'; Found in src/Debug/Dump/Html/HtmlString.php - About 35 mins to fix 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 handleStringToken has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function handleStringToken($token)
{
if ($token === '{') {$this->depth++;
} elseif ($token === '}') { Found in src/Debug/Utility/FindExit.php - About 35 mins to fix 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 addViaRef has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open Found in src/Debug/Abstraction/AbstractObjectProperties.php - About 35 mins to fix 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 clearLogHelper has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private function clearLogHelper(&$log, $clearErrors = false,$entriesKeep = array())
{
$keep =$clearErrors
? array()
: array('error','warn');
Found in src/Debug/Method/Clear.php - About 35 mins to fix

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"

Function buildFooter has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open

    protected function buildFooter()
{
$haveTotal = false;$cells = array();
foreach ($this->options['tableInfo']['columns'] as$colInfo) {
Found in src/Debug/Dump/Html/Table.php - About 35 mins to fix

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"

Function getPhpDocVar has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open

    public function getPhpDocVar(Reflector $reflector) { /** @psalm-suppress NoInterfaceProperties */$name = $reflector->name;$phpDoc = $this->phpDoc->getParsed($reflector);
Found in src/Debug/Abstraction/AbstractObjectHelper.php - About 35 mins to fix

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"

Function processLogEntry has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open

    public function processLogEntry(LogEntry $logEntry) {$method = $logEntry['method']; if (\in_array($method, array('table', 'trace'), true)) {
var $lis = [] var channel var channelName = '' Found in src/Debug/js_src/enhanceMain.js - About 35 mins to fix 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 recordTokenArray has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open  private static function recordTokenArray($token)
{
switch (self::$record) { case 'namespace': switch ($token[0]) {
Found in src/Debug/Utility/UseStatements.php - About 35 mins to fix

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"

Function normalizeInterfaceSubscribers has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open

    private function normalizeInterfaceSubscribers($mixed) { if (\is_string($mixed)) {
// methodName
return array(
Found in src/PubSub/Manager.php - About 35 mins to fix

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"