Showing 4,652 of 306,333 total issues
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return true;
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return $permission;
Function registerFieldDetailsChange
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
registerFieldDetailsChange: function (contents) {
contents.find('[name="mandatory"]').on('change', function (e) {
let currentTarget = $(e.currentTarget);
if (currentTarget.attr('readonly') !== 'readonly') {
var form = currentTarget.closest('.fieldDetailsForm');
- 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 registerDragDropEvent
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
registerDragDropEvent: function (contentData) {
if (contentData == undefined) {
return;
}
const thisInstance = this;
- 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 getHourValues
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
getHourValues: function (list, currentValue) {
let options = '';
for (let key in list) {
//IE Browser consider the prototype properties also, it should consider has own properties only.
if (list.hasOwnProperty(key)) {
- 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 checkChildren
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
checkChildren: function (id, data) {
let self = this,
dataNew = [];
for (let key in data) {
if (data[key].id != id) {
- 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 lockCheckbox
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
lockCheckbox: function (contents) {
contents.on('change', ':checkbox', function (e) {
let currentTarget = $(e.currentTarget);
if (currentTarget.attr('readonly') === 'readonly') {
var status = $(e.currentTarget).is(':checked');
- 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 registerChangeVal
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
registerChangeVal: function (content) {
content.on('change', '.configField', function (e) {
let target = $(e.currentTarget),
params = {
module: app.getModuleName(),
- 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 registerChangeVal
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
registerChangeVal: function (content) {
content.find('.js-config-field').on('change', function (e) {
var target = $(e.currentTarget);
var params = {};
params['type'] = target.data('type');
- 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"