Showing 446 of 948 total issues
Function toScript
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
toScript(indentLevel=1){
let entry=null, out=`{
`;
for(let i=0; i<this.entries.length; i++){
Function init
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
init(){
let im = InspectorManager.getInstance();
// init config
// TODO remove engine configuration
Function toString
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
toString(){
let v = '[', e=null;
//console.log(this);
for(let i=0; i<this.value.length; i++){
e = this.value[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 multiVar
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
multiVar: function(raw_src){
let m = null, v = [];
m = Core.RX.REF_REG_MULT.exec(raw_src);
- 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 parse
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
parse() {
const xmlHeader = this.readChunkHeader();
if (xmlHeader.chunkType !== ChunkType.XML) {
throw new Error('Invalid XML header');
}
- 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 AppFile
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
function AppFile(config){
this.name = null;
this.type = null;
this.size = null;
this.path = 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"
Further reading
Function connect
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
async connect( pIpAddress, pPortNumber, pDevice){
let success = false, wrapper=null;
for(let i in this.bridges){
- 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 fromXml
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
static fromXml(xmlobj){
let intf = new IntentFilter();
if(xmlobj.action != null && xmlobj.action instanceof Array){
for(let i=0; i<xmlobj.action.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 resolveInheritedField
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
function resolveInheritedField(fieldRef, parentClass){
for(let i in parentClass.fields){
if(parentClass.fields[i].name===fieldRef.name){
if(parentClass.fields[i].tags.indexOf('missing')>-1){
return parentClass.fields[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 getBasicBlockByLabel
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
Method.prototype.getBasicBlockByLabel = function(pLabel, pType){
//if(pType == CONST.INSTR_TYPE.IF){
switch(pType)
{
case CONST.INSTR_TYPE.IF:
- 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 parse
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
parse(src){
let ls=src.split(EOL), ln=null, sml=null, obj=null;
//console.log(ls);
for(let l=0; l<ls.length; l++){
- 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 showCFG_old
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
Analyzer.prototype.showCFG_old = function(bblocks, prefix=""){
let pathTRUE = Chalk.green(prefix+" |\n"+prefix+" |\n"+prefix+" |\n"+prefix+" +-----[TRUE]-->");
let path_len = " +-----[TRUE]-->".length;
let pathFALSE = Chalk.red(prefix+" |\n"+prefix+" |\n"+prefix+" |\n"+prefix+" +-----[FALSE]->");
- 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 resolveInheritedMethod
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
function resolveInheritedMethod(methodRef, parentClass){
for(let i in parentClass.methods){
if(parentClass.methods[i].name===methodRef.name){
if(parentClass.methods[i].tags.indexOf('missing')>-1){
return parentClass.methods[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 synchronizePlatform
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
async synchronizePlatform( pName){
let pm = PlatformManager.getInstance(), res=false;
// select platform
switch(pName){
- 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 toScript
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
toScript(indentLevel=1){
let entry=null, out=`{
`;
for(let i=0; i<this.entries.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 scan
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
Scanner.prototype.scan = function(force){
let match = null;
for(let cat in this.rules){
for(let name in this.rules[cat]){
if((this.rules[cat][name] instanceof Rule)
- 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 callgraph_to
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
GraphMaker.prototype.callgraph_to = function(obj, n=1, m=2){
let tree={ name:null, children:null };
// call graph
if(obj instanceof CLASS.Method){
- 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 compare
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Field.prototype.compare = function(field){
let diff = [];
for(let i in this){
switch(i){
Function showCFG
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Analyzer.prototype.showCFG = function(bblocks, offset=0, prefix="", fn=null){
if(bblocks.length==0 || bblocks[offset]==undefined){
Logger.debug(offset+" => not block");
return null;
Function parsePackageList
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
parsePackageList( pPackageListStr, pOptions=''){
var reg = new RegExp("^package:(?<apk_name>.*)");
var packages = [];
if(pPackageListStr.indexOf("error:")==0){