Showing 277 of 350 total issues
File jquery.js
has 4932 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* jQuery JavaScript Library v1.4.4
* http://jquery.com/
*
* Copyright 2010, John Resig
Method suppliers_information
has a Cognitive Complexity of 300 (exceeds 5 allowed). Consider refactoring. Open
def suppliers_information
suppliers = []
case document_format
when :format1
- 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
Method contract_information
has a Cognitive Complexity of 273 (exceeds 5 allowed). Consider refactoring. Open
def contract_information
contract_information_hash = {}
case document_format
when :format1
- 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
Method suppliers_information
has a Cognitive Complexity of 185 (exceeds 5 allowed). Consider refactoring. Open
def suppliers_information(document)
suppliers = []
case document_type(document)
when :standard
- 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
Method procedure_information
has a Cognitive Complexity of 175 (exceeds 5 allowed). Consider refactoring. Open
def procedure_information
procedure_information_hash = {}
case document_format
when :format1
- 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 jQuery
has 548 lines of code (exceeds 25 allowed). Consider refactoring. Open
var jQuery = (function() {
// Define a local copy of jQuery
var jQuery = function( selector, context ) {
// The jQuery object is actually just the init constructor 'enhanced'
Method performance_information
has a Cognitive Complexity of 119 (exceeds 5 allowed). Consider refactoring. Open
def performance_information
performance_information_hash = {}
case document_format
when :format1
- 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
Method additional_information
has a Cognitive Complexity of 111 (exceeds 5 allowed). Consider refactoring. Open
def additional_information
additional_information_hash = {}
case document_format
when :format1
- 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
Method customer_information
has a Cognitive Complexity of 105 (exceeds 5 allowed). Consider refactoring. Open
def customer_information
customer_information_hash = {}
case document_format
when :format1
- 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
Method show
has a Cognitive Complexity of 74 (exceeds 5 allowed). Consider refactoring. Open
def show
@dataset_description = DatasetDescription.find(params[:id])
@field_descriptions = @dataset_description.visible_field_descriptions.includes(:data_format)
@dataset_class = @dataset_description.dataset_model
@title = @dataset_description.title
- 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 asmSelect
has 247 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.fn.asmSelect = function(customOptions) {
var options = {
listType: 'ol', // Ordered list 'ol', or unordered list 'ul'
Method suppliers_information
has 242 lines of code (exceeds 25 allowed). Consider refactoring. Open
def suppliers_information
suppliers = []
case document_format
when :format1
Method contract_information
has 219 lines of code (exceeds 25 allowed). Consider refactoring. Open
def contract_information
contract_information_hash = {}
case document_format
when :format1
Function ajax
has 193 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function( origSettings ) {
var s = jQuery.extend(true, {}, jQuery.ajaxSettings, origSettings),
jsonp, status, data, type = s.type.toUpperCase(), noContent = rnoContent.test(type);
s.url = s.url.replace( rhash, "" );
Method get_formatted_value
has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring. Open
def get_formatted_value(field_description)
value = get_value(field_description)
# Apply format
data_format = field_description.data_format
if data_format
- 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 tooltip
has 164 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.fn.tooltip = function(instanceSettings){
$.fn.tooltip.defaultsSettings = {
attributeName:'title',
borderColor:'#ccc',
Method performance_information
has 141 lines of code (exceeds 25 allowed). Consider refactoring. Open
def performance_information
performance_information_hash = {}
case document_format
when :format1
Method procedure_information
has 137 lines of code (exceeds 25 allowed). Consider refactoring. Open
def procedure_information
procedure_information_hash = {}
case document_format
when :format1
Method set_up_relation
has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring. Open
def set_up_relation
dataset_description.relations(true).each do |relation|
left_association = (relation.relationship_dataset_description.identifier < dataset_description.identifier)
if relation.respond_to?(:morph) && relation.morph?
- 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
Method create_predicates_from_tokens
has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring. Open
def create_predicates_from_tokens(tokens)
# puts "==> predicate from tokens #{tokens}"
tokens.each { |token|
# puts "--- token '#{token}'"
- 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"