Showing 2,021 of 3,362 total issues
Function getDefaultsForNode8
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function getDefaultsForNode8(features) {
const combined = {
presets: [],
plugins: [getReifyPlugin(features)]
};
- 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 initialize
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
initialize(options) {
var self = this;
buildmessage.assertInCapture();
options = options || {};
- 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 toArchArray
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function toArchArray(arch) {
if (! Array.isArray(arch)) {
arch = arch ? [arch] : compiler.ALL_ARCHES;
}
- 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 wipeCachedPackages
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
wipeCachedPackages(packages) {
var self = this;
if (packages) {
// Wipe specific packages.
_.each(packages, function (packageName) {
- 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 createTable
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
createTable: function (txn) {
var self = this;
var sql = 'CREATE TABLE IF NOT EXISTS ' + self.name + '(';
for (var i = 0; i < self.jsonFields.length; i++) {
- 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 getReifyOptions
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function getReifyOptions(features) {
const reifyOptions = {
avoidModernSyntax: true,
enforceStrictMode: false,
dynamicImport: true
- 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 _extractAndConvert
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
exports._extractAndConvert = function (packageTarball, forceConvert) {
var targetDirectory = files.mkdtemp();
files.extractTarGz(packageTarball, targetDirectory, {
forceConvert: forceConvert
});
- 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 getPackagesToLoadFirst
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
getPackagesToLoadFirst: function (packageMap) {
var self = this;
var packages = {};
var processUse = function (use) {
// We don't have to build weak or unordered deps first (eg they can't
- 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 writeFile
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
var writeFile = Profile("bundler writeFile", function (file, builder, options) {
if (! file.targetPath) {
throw new Error("No targetPath?");
}
- 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 getFooter
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
var getFooter = function ({
name,
exported,
exportsName,
}) {
- 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 _runCompilerPlugins
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
_runCompilerPlugins({
minifiers = [],
minifyMode = "development",
}) {
buildmessage.assertInJob();
- 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 tryToParse
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function tryToParse(source, hash) {
if (hash && AST_CACHE.has(hash)) {
return AST_CACHE.get(hash);
}
- 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 createApp
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
createApp(to, template, options) {
options = options || {};
const absoluteTo = files.pathJoin(this.cwd, to);
const absoluteFrom = files.pathJoin(
files.convertToStandardPath(__dirname),
- 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 finalize
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
finalize() {
if (this._finalizerPromise) {
this._finalizerPromise.await();
} else if (this._lazyFinalizer) {
const finalize = this._lazyFinalizer;
- 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 runMain
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
var runMain = Profile("Run main()", function () {
// find and run main()
// XXX hack. we should know the package that contains main.
var mains = [];
var globalMain;
- 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 execFileAsync
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
exports.execFileAsync = function (file, args, opts) {
opts = opts || {};
var child_process = require('child_process');
var { eachline } = require('./eachline');
var p = child_process.spawn(file, args, opts);
- 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 logAppOutput
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
logAppOutput: function (line, isStderr) {
var self = this;
var Log = getLoggingPackage();
- 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 shouldSkipCurrentTest
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
const shouldSkipCurrentTest = ({currentTestIndex, options: {skip, limit} = {}}) => {
if (!skip && !limit) {
return false;
}
if (limit && skip) {
- 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 startCheckForLiveParent
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
var startCheckForLiveParent = function (parentPid) {
if (parentPid) {
if (! bootUtils.validPid(parentPid)) {
console.error("METEOR_PARENT_PID must be a valid process ID.");
process.exit(1);
- 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 capture
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function capture(options, f) {
var messageSet = new MessageSet;
var parentMessageSet = currentMessageSet.get();
var 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"