ltgcgo/octavia

View on GitHub
src/state/emitGlobal.js

Summary

Maintainability
B
4 hrs
Test Coverage

Showing 2 of 2 total issues

Function sysexBitmap has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

let sysexBitmap = function (frameData, type = "xg", frameId = 0, noCopy) {
if (!frameData?.length) {
throw Error(`Blank frame data`);
};
// 0 for XG, 1 for GS, 2 for NS5R
Severity: Major
Found in src/state/emitGlobal.js - About 2 hrs to fix

    Function sysexBitmap has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
    Open

    let sysexBitmap = function (frameData, type = "xg", frameId = 0, noCopy) {
    if (!frameData?.length) {
    throw Error(`Blank frame data`);
    };
    // 0 for XG, 1 for GS, 2 for NS5R
    Severity: Minor
    Found in src/state/emitGlobal.js - About 1 hr to fix
    Category
    Status