Showing 179 of 497 total issues
Function initializer
has 68 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
initializer: function(args) {
function onTitleClicked(e, a) {
var i = a.findSection(e.target);
if (i >= 0) {
File modules.js
has 271 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
var modules= [];
modules[modules.length++] = {
"name":"xpath",
"container": {
File Grouper.js
has 268 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
(function() {
/**
* @class Grouper
*/
Function collapse
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
collapse: function(expanded)
{
if (Y.Lang.isValue(this.groupContainer))
return this.groupContainer; //This group is already collapsed
Function positionTerminals
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
positionTerminals: function()
{
var terminals = {};
for (var i in this.options.terminals)
Consider simplifying this complex logical expression. Open
Open
if (rule &&
(rule == TOK_DIV ||
rule == TOK_MOD ||
rule == TOK_AND ||
rule == TOK_OR) &&
Function initializer
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
initializer: function(args) {
var oMenuBar = new YAHOO.widget.MenuBar("menuContainer2", {
autosubmenudisplay: true,
hidedelay: 750,
Function LocalStorageSync
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function LocalStorageSync(key) {
var localStorage;
if (!key) {
Y.error('No storage key specified.');
Function getOverridesFromUI
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getOverridesFromUI: function(containerUIMap, groupUIMap)
{
containerOverrides = [];
groupOverrides = [];
Function LocalStorageSync
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function LocalStorageSync(key) {
var localStorage;
if (!key) {
Y.error('No storage key specified.');
Function LocalStorageSync
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function LocalStorageSync(key) {
var localStorage;
if (!key) {
Y.error('No storage key specified.');
Function LocalStorageSync
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function LocalStorageSync(key) {
var localStorage;
if (!key) {
Y.error('No storage key specified.');
Function LocalStorageSync
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function LocalStorageSync(key) {
var localStorage;
if (!key) {
Y.error('No storage key specified.');
Function xpathMatchStack
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function xpathMatchStack(stack, pattern) {
// NOTE(mesch): The stack matches for variable cardinality are
// greedy but don't do backtracking. This would be an issue only
// with rules of the form A* A, i.e. with an element with variable
Function render
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render: function() {
Y.LayerContainer.superclass.render.call(this);
this.subLayer = new Y.Layer({layerMap: false, parentEl: this.bodyEl});
Function xpathParseInit
has 53 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function xpathParseInit() {
if (xpathRules.length) {
return;
}
Function removeChild
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
Open
XNode.prototype.removeChild = function(node) {
var newChildren = [];
for (var i = 0; i < this.childNodes.length; ++i) {
var c = this.childNodes[i];
if (c != node) {
- 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 replaceChild
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
Open
XNode.prototype.replaceChild = function(newNode, oldNode) {
if (oldNode == newNode) {
return;
}
- 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 evaluate
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
BinaryExpr.prototype.evaluate = function(ctx) {
var ret;
switch (this.op.value) {
case 'or':
ret = new BooleanValue(this.expr1.evaluate(ctx).booleanValue() ||
Function Php
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
SyntaxHighlighter.brushes.Php = function()
{
var funcs = 'abs acos acosh addcslashes addslashes ' +
'array_change_key_case array_chunk array_combine array_count_values array_diff '+
'array_diff_assoc array_diff_key array_diff_uassoc array_diff_ukey array_fill '+