Showing 23 of 31 total issues
Method __construct
has 305 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function __construct()
{
/* mandatory requirements follow */
$installedPhpVersion = PHP_VERSION;
File SymfonyRequirements.php
has 503 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/*
* This file is part of the Symfony package.
*
File ZeroClipboard.js
has 460 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*!
* ZeroClipboard
* The ZeroClipboard library provides an easy way to copy text to the clipboard using an invisible Adobe Flash movie and a JavaScript interface.
* Copyright (c) 2013 Jon Rohan, James M. Greene
* Licensed MIT
Function __construct
has a Cognitive Complexity of 37 (exceeds 5 allowed). Consider refactoring. Open
Open
public function __construct()
{
/* mandatory requirements follow */
$installedPhpVersion = PHP_VERSION;
- 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 create
has 74 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function create(button) {
if (typeof button === "undefined") {
console.warn("Ladda button target must be defined.");
return;
}
Function initVML
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function initVML() {
function vml(tag, attr) {
return createEl("<" + tag + ' xmlns="urn:schemas-microsoft.com:vml" class="spin-vml">', attr);
}
sheet.addRule(".spin-vml", "behavior:url(#default#VML)");
Function receiveEvent
has 50 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ZeroClipboard.prototype.receiveEvent = function(eventName, args) {
eventName = eventName.toString().toLowerCase().replace(/^on/, "");
var element = currentElement;
var performCallbackAsync = true;
switch (eventName) {
Function lines
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Spinner.prototype.lines = function(el, o) {
var r = o.length + o.width, s = 2 * r;
function grp() {
return css(vml("group", {
coordsize: s + " " + s,
Function __construct
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
Open
public function __construct($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null, $optional = false)
{
$cfgValue = ini_get($cfgName);
if (is_callable($evaluation)) {
- 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 spin
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
spin: function(target) {
this.stop();
var self = this, o = self.opts, el = self.el = css(createEl(0, {
className: o.className
}), {
Function _getDOMObjectPosition
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var _getDOMObjectPosition = function(obj) {
var info = {
left: 0,
top: 0,
width: 0,
Function _bridge
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var _bridge = function() {
var flashBridge, len;
var client = ZeroClipboard.prototype._singleton;
var container = document.getElementById("global-zeroclipboard-html-bridge");
if (!container) {
Function lines
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
lines: function(el, o) {
var i = 0, start = (o.lines - 1) * (1 - o.direction) / 2, seg;
function fill(color, shadow) {
return css(createEl(), {
position: "absolute",
Function bind
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function bind(target, options) {
options = options || {};
var targets = [];
if (typeof target === "string") {
targets = toArray(document.querySelectorAll(target));
Function _vars
has 26 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var _vars = function(options) {
var str = [];
var origins = [];
if (options.trustedOrigins) {
if (typeof options.trustedOrigins === "string") {
Method __construct
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function __construct($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null, $optional = false)
Avoid deeply nested control flow statements. Open
Open
if (className.indexOf(" " + classNames[c] + " ") < 0) {
setClass += " " + classNames[c];
}
Method addPhpIniRecommendation
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function addPhpIniRecommendation($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null)
Method addPhpIniRequirement
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function addPhpIniRequirement($cfgName, $evaluation, $approveCfgAbsence = false, $testMessage = null, $helpHtml = null, $helpText = null)
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function __construct($fulfilled, $testMessage, $helpHtml, $helpText = null, $optional = false)