Showing 53 of 77 total issues
Function createSingleMessageEntry
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
const createSingleMessageEntry = ($entry, type) => {
return `
<div class="rbutr-message-entry">
<h6>${$entry[type].title}</h6>
<a href="${$entry[type].url}">${$entry[type].url}</a>
Function buildDomStructure
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function buildDomStructure(input) {
var $wrapper = $(html.wrapper), $dropdown = $(html.dropdown), $input = $(input), $hint = $(html.hint);
$wrapper = $wrapper.css(css.wrapper);
$dropdown = $dropdown.css(css.dropdown);
$hint.css(css.hint).css({
Function rstr2any
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
Open
function rstr2any(input, encoding)
{
var divisor = encoding.length;
var i, j, q, x, quotient;
- 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 md5_ii
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
function md5_ii(a, b, c, d, x, s, t)
Function md5_gg
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
function md5_gg(a, b, c, d, x, s, t)
Function md5_ff
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
function md5_ff(a, b, c, d, x, s, t)
Function md5_hh
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
function md5_hh(a, b, c, d, x, s, t)
Avoid deeply nested control flow statements. Open
Open
if (msg.status === 'success') {
popup.msg.add('info', msg.result);
} else if (msg.status === 'error') {
popup.msg.add('error', msg.result);
}
Avoid deeply nested control flow statements. Open
Open
} else if (msg.response === 'submitRebuttalRequest') {
if (msg.status === 'success') {
popup.msg.add('info', msg.result);
} else if (msg.status === 'error') {
popup.msg.add('error', msg.result);
Function md5_cmn
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
function md5_cmn(q, a, b, x, s, t)
Function Message
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Open
const Message = () => {
'use strict';
const $messageContainer = document.getElementById('messages');
- 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
Avoid too many return
statements within this function. Open
Open
return true;
Avoid too many return
statements within this function. Open
Open
return true;