Showing 1,567 of 3,608 total issues
Function MappingEditor
has 229 lines of code (exceeds 25 allowed). Consider refactoring. Open
DW.MappingEditor = function(entityType, filters, details, specials) {
var self = this;
var shareButton = $("#share-button");
var shareWidget = $("#share-widget");
var shareWidgetDoneButton = $("#share-widget-done");
Function dwTable
has 226 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.fn.dwTable = function (options) {
function continue_dwtable_creation() {
var sliceGroups = function(data, start, length) {
var newData = [];
Function json_parse
has 222 lines of code (exceeds 25 allowed). Consider refactoring. Open
var json_parse = (function () {
"use strict";
// This is a function that can parse a JSON text, producing a JavaScript
// data structure. It is a simple, recursive descent parser. It does not use
Function retrocycle
has a Cognitive Complexity of 56 (exceeds 5 allowed). Consider refactoring. Open
JSON.retrocycle = function retrocycle($) {
"use strict";
// Restore an object that was reduced by decycle. Members whose values are
// objects of the form
- 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 selectList
has 217 lines of code (exceeds 25 allowed). Consider refactoring. Open
$.selectList = function (select, options) {
var
$selectSingle,
Function continue_dwtable_creation
has 213 lines of code (exceeds 25 allowed). Consider refactoring. Open
function continue_dwtable_creation() {
var sliceGroups = function(data, start, length) {
var newData = [];
var groupKeys = Object.keys(data);
Function ajax
has 208 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function( origSettings ) {
var s = jQuery.extend(true, {}, jQuery.ajaxSettings, origSettings);
var jsonp, status, data,
callbackContext = origSettings && origSettings.context || s,
Function ContactsGroupViewModel
has 208 lines of code (exceeds 25 allowed). Consider refactoring. Open
function ContactsGroupViewModel() {
var self = this;
self.groups = ko.observableArray();
self.groupButtonText = ko.observable(gettext("Add"));
self.newGroupName = DW.ko.createValidatableObservable({value: ""});
Function _init
has 208 lines of code (exceeds 25 allowed). Consider refactoring. Open
_init: function () {
var self = this;
var q = this.options;
this.newly_added_question = ko.observable(q.newly_added_question);
this.range_min = DW.ko.createValidatableObservable({value: q.range.min});
Function show_log
has a Cognitive Complexity of 53 (exceeds 5 allowed). Consider refactoring. Open
def show_log(request):
organization = get_organization(request)
org_id = organization.org_id
args = dict(organization=org_id)
time_delta = get_country_time_delta(organization.country)
- 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 setDocument
has 200 lines of code (exceeds 25 allowed). Consider refactoring. Open
setDocument = Sizzle.setDocument = function( node ) {
var doc = node ? node.ownerDocument || node : preferredDoc,
parent = doc.defaultView;
// If no document and documentElement is available, return
File views.py
has 498 lines of code (exceeds 250 allowed). Consider refactoring. Open
# vim: ai ts=4 sts=4 et sw=4 encoding=utf-8
import json
import datetime
from operator import itemgetter
Function SmsViewModel
has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring. Open
function SmsViewModel(){
var self = this;
var smsTextArea = $("#sms-text");
- 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 saveAs
has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring. Open
var saveAs = saveAs || (function(view) {
"use strict";
// IE <10 is explicitly unsupported
if (typeof view === "undefined" || typeof navigator !== "undefined" && /MSIE [1-9]\./.test(navigator.userAgent)) {
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 jsDump
has 187 lines of code (exceeds 25 allowed). Consider refactoring. Open
QUnit.jsDump = (function() {
function quote( str ) {
return "\"" + str.toString().replace( /"/g, "\\\"" ) + "\"";
}
function literal( o ) {
File analysis.js
has 477 lines of code (exceeds 250 allowed). Consider refactoring. Open
$(document).ready(function () {
var analysisTable,
colCustomization;
Function ColCustomWidget
has 184 lines of code (exceeds 25 allowed). Consider refactoring. Open
var ColCustomWidget = (function ($) {
function ColCustomWidget(customizationHeader) {
this.$columnWidget = $(".customization-widget");
this.$custMenu = $(".customization-menu");
this.$colWidgetActions = $("#customize-btn, .customization-widget-close, .customize-list-link");
File daterangepicker.jQuery.withoutdrilldown.js
has 473 lines of code (exceeds 250 allowed). Consider refactoring. Open
jQuery.fn.daterangepicker = function(settings){
var rangeInput = jQuery(this);
//defaults
`` has 52 functions (exceeds 20 allowed). Consider refactoring. Open
intellisense.annotate(jQuery, {
'ajax': function() {
/// <signature>
/// <summary>Perform an asynchronous HTTP (Ajax) request.</summary>
/// <param name="url" type="String">A string containing the URL to which the request is sent.</param>
Function migrate_01
has a Cognitive Complexity of 47 (exceeds 5 allowed). Consider refactoring. Open
def migrate_01(managers, map_fun_form_model_with_date_field_docs):
failed_managers = []
for manager in managers:
try:
print manager.database
- 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"