Showing 390 of 605 total issues
Function xPathStep
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
function xPathStep(nodes, steps, step, input, ctx) {
Function loadURL
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Spry.Utils.loadURL = function(method, url, async, callback, opts)
Function makeFunctionCallExpr2
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
function makeFunctionCallExpr2(name, pareno, arg1, args, parenc) {
Function request
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
request: function(form, options) {
form = $(form), options = Object.clone(options || { });
var params = options.parameters, action = form.readAttribute('action') || '';
if (action.blank()) action = window.location.href;
- 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 ValidationTextField
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Spry.Widget.ValidationTextField = function(element, type, options)
{
type = Spry.Widget.Utils.firstValid(type, "none");
if (typeof type != 'string') {
this.showError('The second parameter in the constructor should be the validation type, the options are the third parameter.');
- 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 debugOut
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Spry.Debug.debugOut = function(str, bgColor)
{
if (!Spry.Debug.debugWindow)
{
Spry.Debug.createDebugWindow();
- 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 lang
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
'lang': function(ctx) {
assert(this.args.length == 1);
var lang = this.args[0].evaluate(ctx).stringValue();
var xmllang;
var n = ctx.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 $
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Spry.$ = function(element)
{
if (arguments.length > 1)
{
for (var i = 0, elements = [], length = arguments.length; i < length; i++)
- 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 _children
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
_children: function(element, children) {
if(children.tagName) {
element.appendChild(children);
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 extractRequestOptions
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Spry.Utils.loadURL.Request.prototype.extractRequestOptions = function(opts, undefineRequestProps)
{
if (!opts)
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 attach
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
attach: function(rgn, node, value)
{
if (value)
{
rowNumAttr = node.attributes.getNamedItem("spryevenrownumber");
- 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
Avoid too many return
statements within this function. Open
return 0;
Avoid too many return
statements within this function. Open
return ( diff % first == 0 && diff / first >= 0 );
Avoid too many return
statements within this function. Open
return element;
Avoid too many return
statements within this function. Open
return false;
Avoid too many return
statements within this function. Open
return diff == 0;
Avoid too many return
statements within this function. Open
if (!responder) return element;
Avoid too many return
statements within this function. Open
return true;
Avoid too many return
statements within this function. Open
return false;
Avoid too many return
statements within this function. Open
return date;