Showing 224 of 303 total issues
Function Dropzone
has a Cognitive Complexity of 1133 (exceeds 5 allowed). Consider refactoring. Open
var Dropzone = function (_Emitter) {
_inherits(Dropzone, _Emitter);
_createClass(Dropzone, null, [{
key: "initClass",
- 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
File jQuery.js
has 6789 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*!
* jQuery JavaScript Library v3.4.1
* https://jquery.com/
*
* Includes Sizzle.js
Function Dropzone
has 1794 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Dropzone = function (_Emitter) {
_inherits(Dropzone, _Emitter);
_createClass(Dropzone, null, [{
key: "initClass",
Function Sizzle
has 1457 lines of code (exceeds 25 allowed). Consider refactoring. Open
(function(window) {
var i,
support,
Expr,
File dropzone.js
has 2373 lines of code (exceeds 250 allowed). Consider refactoring. Open
"use strict";
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
Function initClass
has 354 lines of code (exceeds 25 allowed). Consider refactoring. Open
value: function initClass() {
// Exposing the emitter class, mainly for tests
this.prototype.Emitter = Emitter;
Function ajax
has 252 lines of code (exceeds 25 allowed). Consider refactoring. Open
ajax: function(url, options) {
// If url is an object, simulate pre-1.5 signature
if (typeof url === "object") {
options = url;
Function setDocument
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
setDocument = Sizzle.setDocument = function(node) {
var hasCompare, subWindow,
doc = node ? node.ownerDocument || node : preferredDoc;
// Return early if doc is invalid or already selected
Function Deferred
has 181 lines of code (exceeds 25 allowed). Consider refactoring. Open
Deferred: function(func) {
var tuples = [
// action, add listener, callbacks,
// ... .then handlers, argument index, [final state]
Function Emitter
has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring. Open
var Emitter = function () {
function Emitter() {
_classCallCheck(this, Emitter);
}
- 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 getElements
has a Cognitive Complexity of 41 (exceeds 5 allowed). Consider refactoring. Open
Dropzone.getElements = function (els, name) {
var el = void 0,
elements = void 0;
if (els instanceof Array) {
elements = [];
- 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 ExifRestore
has a Cognitive Complexity of 41 (exceeds 5 allowed). Consider refactoring. Open
var ExifRestore = function () {
function ExifRestore() {
_classCallCheck(this, ExifRestore);
}
- 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 ExifRestore
has 156 lines of code (exceeds 25 allowed). Consider refactoring. Open
var ExifRestore = function () {
function ExifRestore() {
_classCallCheck(this, ExifRestore);
}
User
has 42 methods (exceeds 20 allowed). Consider refactoring. Open
@Entity
@Inheritance(strategy = InheritanceType.JOINED)
/**
* @author Milione Vincent class a user on platform
*/
Function init
has 137 lines of code (exceeds 25 allowed). Consider refactoring. Open
value: function init() {
var _this3 = this;
// In case it isn't set already
if (this.element.tagName === "form") {
Function discover
has a Cognitive Complexity of 35 (exceeds 5 allowed). Consider refactoring. Open
Dropzone.discover = function () {
var dropzones = void 0;
if (document.querySelectorAll) {
dropzones = document.querySelectorAll(".dropzone");
} else {
- 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 defaultPrefilter
has 122 lines of code (exceeds 25 allowed). Consider refactoring. Open
function defaultPrefilter(elem, props, opts) {
var prop, value, toggle, hooks, oldfire, propTween, restoreDisplay, display,
isBox = "width" in props || "height" in props,
anim = this,
orig = {},
Function Callbacks
has 121 lines of code (exceeds 25 allowed). Consider refactoring. Open
jQuery.Callbacks = function(options) {
// Convert options from String-formatted to Object-formatted if needed
// (we check in cache first)
options = typeof options === "string" ?
Function isBrowserSupported
has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring. Open
Dropzone.isBrowserSupported = function () {
var capableBrowser = true;
if (window.File && window.FileReader && window.FileList && window.Blob && window.FormData && document.querySelector) {
if (!("classList" in document.createElement("a"))) {
- 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 then
has 102 lines of code (exceeds 25 allowed). Consider refactoring. Open
then: function(onFulfilled, onRejected, onProgress) {
var maxDepth = 0;
function resolve(depth, deferred, handler, special) {
return function() {