Showing 5,781 of 10,536 total issues
Function ngMessageDirectiveFactory
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
function ngMessageDirectiveFactory(isDefault) {
return ['$animate', function($animate) {
return {
restrict: 'AE',
transclude: 'element',
Function SelectionManager
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
function SelectionManager() {
var t = this;
// exports
Function discover
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
Dropzone.discover = function () {
var dropzones;
if (document.querySelectorAll) {
dropzones = document.querySelectorAll(".dropzone");
Function limitRow
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
limitRow: function(row, levelLimit) {
var _this = this;
var view = this.view;
var rowStruct = this.rowStructs[row];
var moreNodes = []; // array of "more" <a> links and <td> DOM nodes
Function createThumbnailFromUrl
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
value: function createThumbnailFromUrl(file, width, height, resizeMethod, fixOrientation, callback, crossOrigin) {
var _this14 = this;
// Not using `new Image` here because of a bug in latest Chrome versions.
// See https://github.com/enyo/dropzone/pull/226
Function ProgressBar
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
const ProgressBar = () => {
return (
<Fragment>
<PageHeader
title="Progress"
Function AddAnotherList
has 70 lines of code (exceeds 25 allowed). Consider refactoring. Open
const AddAnotherList = () => {
const { kanbanColumns, kanbanColumnsDispatch } = useContext(KanbanContext);
const [showForm, setShowForm] = useState(false);
const [columnHeaderTitle, setColumnHeaderTitle] = useState('');
File Billing.js
has 283 lines of code (exceeds 250 allowed). Consider refactoring. Open
import React, { useState } from 'react';
import { Link } from 'react-router-dom';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import {
Button,
File SpaceEnvironmentMonitor.js
has 282 lines of code (exceeds 250 allowed). Consider refactoring. Open
import React, { Fragment, useEffect, useState } from 'react';
import {
Breadcrumb,
BreadcrumbItem,
Card,
Function post
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
post: function(scope, elem, attr, ngModel) {
var needsTabIndex = shouldAttachAttr('tabindex', 'tabindex', elem, false);
function ngAriaWatchModelValue() {
return ngModel.$modelValue;
Function renderEventRow
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
renderEventRow: function(row, rowSegs) {
var view = this.view;
var colCnt = view.colCnt;
var segLevels = this.buildSegLevels(rowSegs); // group into sub-arrays of levels
var levelCnt = Math.max(1, segLevels.length); // ensure at least one level
Function bindContainerTouchEvents
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
bindContainerTouchEvents: function(){
var touchStartScale,
touchStartDistance,
map = this,
touchX,
Function EventTicket
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
const EventTicket = () => {
// Data
const { loading: loadingTickets, data: tickets, setData: setTickets } = useFakeFetch(rawEventTickets);
// Change Ticket
Function getOption
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
const getOption = (data, colors, isDark) => {
const grays = getGrays(isDark);
return {
dataset: { source: data },
tooltip: {
Function on_post
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_post(req, resp):
"""Handles POST requests"""
admin_control(req)
try:
raw_json = req.stream.read().decode('utf-8')
- 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 on_get
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_get(req, resp):
if 'API-KEY' not in req.headers or \
not isinstance(req.headers['API-KEY'], str) or \
len(str.strip(req.headers['API-KEY'])) == 0:
access_control(req)
- 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 on_get
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_get(req, resp, id_):
if 'API-KEY' not in req.headers or \
not isinstance(req.headers['API-KEY'], str) or \
len(str.strip(req.headers['API-KEY'])) == 0:
access_control(req)
- 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 on_get
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_get(req, resp, id_):
if 'API-KEY' not in req.headers or \
not isinstance(req.headers['API-KEY'], str) or \
len(str.strip(req.headers['API-KEY'])) == 0:
access_control(req)
- 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 on_put
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_put(req, resp, id_):
"""Handles PUT requests"""
admin_control(req)
if not id_.isdigit() or int(id_) <= 0:
raise falcon.HTTPError(status=falcon.HTTP_400, title='API.BAD_REQUEST',
- 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 on_get
has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring. Open
def on_get(req, resp, id_):
if 'API-KEY' not in req.headers or \
not isinstance(req.headers['API-KEY'], str) or \
len(str.strip(req.headers['API-KEY'])) == 0:
access_control(req)
- 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"