Showing 324 of 527 total issues
Function exports
has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring. Open
module.exports = (dust) => {
function renderParameter(name, chunk, context, bodies, params) {
if (params && params[name]) {
if (typeof params[name] === 'function') {
- 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 format
has 192 lines of code (exceeds 25 allowed). Consider refactoring. Open
module.exports.format = (req, res, next) => {
var isYAML = (/(.*).yaml/).test(req.path),
isJSON = !isYAML && ((/(.*).json$/).test(req.path) || (/^\/api\//).test(req.path)),
isXLS = !isJSON && !isYAML && (/(.*).xlsx/).test(req.path),
isHTML = !isJSON && !isYAML && !isXLS;
Function exports
has 188 lines of code (exceeds 25 allowed). Consider refactoring. Open
module.exports = function (connect) {
/**
* Connect's Store.
*/
Function table
has 187 lines of code (exceeds 25 allowed). Consider refactoring. Open
static table(inputQuery, inputColumns, options) {
SCli.debug(__MODULE_NAME, 'table', this.model.tableName, JSON.stringify(inputQuery), JSON.stringify(inputColumns), JSON.stringify(options));
let
query,
columns = inputColumns,
Function exports
has 181 lines of code (exceeds 25 allowed). Consider refactoring. Open
.then((FlyWeight, TaxonomyType) => {
SCli.debug(__MODULE_NAME, 'READY');
class TaxonomyModel extends Model {
Function constructor
has 178 lines of code (exceeds 25 allowed). Consider refactoring. Open
constructor(element) {
var
self = this;
this._search = lackey.select('[data-lky-hook="table.filter"]')[0];
this._root = element;
File index.js
has 448 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* eslint no-cond-assign:0, no-new:0 no-param-reassign:0 */
/* jslint browser:true, node:true, esnext:true */
'use strict';
/*
Copyright 2016 Enigma Marketing Services Limited
File block-editor.js
has 443 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* eslint no-cond-assign:0, no-new:0, no-use-before-define:0, no-continue:0 */
/* jslint browser:true, node:true, esnext:true */
'use strict';
/*
Copyright 2016 Enigma Marketing Services Limited
Function exports
has 163 lines of code (exceeds 25 allowed). Consider refactoring. Open
module.exports = (gulp, projectDIR) => {
let lackeyDIR = path.resolve(__dirname + '/..'),
htDocs = projectDIR + '/htdocs';
Function exports
has 161 lines of code (exceeds 25 allowed). Consider refactoring. Open
module.exports = () => new Promise((resolve, reject) => {
atomus()
.html('<html></html>')
.ready(function (errors, window) {
try {
Function exports
has a Cognitive Complexity of 42 (exceeds 5 allowed). Consider refactoring. Open
module.exports = () => new Promise((resolve, reject) => {
atomus()
.html('<html></html>')
.ready(function (errors, window) {
try {
- 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 exports
has a Cognitive Complexity of 40 (exceeds 5 allowed). Consider refactoring. Open
module.exports = dust => {
/**
* Editable DUSTJS helper
* @param {Chunk} chunk
- 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 exports
has 141 lines of code (exceeds 25 allowed). Consider refactoring. Open
.then((Taggable) => {
SCli.debug(__MODULE_NAME, 'READY');
require('./generator');
Function render
has 140 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
debug('render');
let
File index.js
has 399 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* eslint no-underscore-dangle:0 */
/* jslint node:true, esnext:true */
/* globals LACKEY_PATH */
'use strict';
Function exports
has a Cognitive Complexity of 35 (exceeds 5 allowed). Consider refactoring. Open
module.exports = function (connect) {
/**
* Connect's Store.
*/
- 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 exports
has a Cognitive Complexity of 35 (exceeds 5 allowed). Consider refactoring. Open
.then((Taggable, QueryBuilder) => {
SCli.debug(__MODULE_NAME, 'READY');
class MediaModel extends Model {
- 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 exports
has 129 lines of code (exceeds 25 allowed). Consider refactoring. Open
.then((Role, User, TaxonomyType, Taxonomy, Template, Media, Content) => {
class Serializer {
static all() {
let result = {};
Function ajax
has a Cognitive Complexity of 34 (exceeds 5 allowed). Consider refactoring. Open
ajax: function (path, method, data, raw) {
return new Promise(function (resolve, reject) {
var xhr = new XMLHttpRequest(),
- 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 page.js
has 378 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* jslint esnext:true, node:true */
/* globals LACKEY_PATH */
'use strict';
/*
Copyright 2016 Enigma Marketing Services Limited