Showing 446 of 948 total issues
Function toJsonObject
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Hook.prototype.toJsonObject = function(){
let o = new Object();
o.id = this.id;
o.parentID = this.parentID;
o.color = this.color;
- 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 enumerateLocal
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
enumerateLocal(){
let res = [], p=null;
let ws = _path_.join(__dirname, '..', 'inspectors'); // this.engine.workspace.getPluginsFolderLocation();
let files = _fs_.readdirSync(ws);
- 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 write
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
write(){
let str=` [
`;
for(let i=0; i<this.data.length; i++){
if(typeof this.data[i] == 'string'){
- 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 is
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Param.prototype.is = function(arg){
let i=0;
if((i=arg.indexOf("="))>-1){
if(this.name instanceof Array)
return this.name.indexOf(arg.substr(0,i))>-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 methodPretty
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Disassembler.prototype.methodPretty = function(method){
let bb=null, txt="", ignore=[], state={};
console.log("\n "+method.signature());
for(let i in method.instr){
- 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 usePlatform
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
async usePlatform( pVersion){
// old
// this.config.platform_target = pVersion;
let pm = this.engine.getPlatformManager(), platform = null;
- 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"