Showing 75 of 2,705 total issues
Avoid too many return
statements within this function. Open
return Outcome().POST("delete_module", True, module_code)
Avoid too many return
statements within this function. Open
return False
Avoid too many return
statements within this function. Open
return Outcome().POST("edit_all_mountings_and_quotas", False, None)
Avoid too many return
statements within this function. Open
return False
Avoid too many return
statements within this function. Open
return Outcome().POST("edit_all_mountings_and_quotas", False, None)
Avoid too many return
statements within this function. Open
return input_data
Avoid too many return
statements within this function. Open
return Outcome().POST("edit_all_mountings_and_quotas", False, None)
Avoid too many return
statements within this function. Open
return Outcome().POST("edit_all_mountings_and_quotas", False, None)
Avoid too many return
statements within this function. Open
return Outcome().POST("edit_all_mountings_and_quotas", True, None)
Function toggleFilters
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function toggleFilters() {
var elements = document.getElementsByClassName("filter")
if (elements[0].hasAttribute("hidden")) {
document.getElementById("chevron").className="glyphicon glyphicon-chevron-up"
for(var i=0; i < elements.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 replace_null_with_dash
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def replace_null_with_dash(table):
'''
Changes all the NULL values found in the table to '-'
This function supports a 2D table.
'''
- 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 get_quota_of_target_tenta_ay_sem
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def get_quota_of_target_tenta_ay_sem(code, ay_sem):
'''
Get the quota of a mod in a target tentative AY/Sem (if any)
'''
number_of_attempts = 0
- 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 get_quota_of_target_fixed_ay_sem
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def get_quota_of_target_fixed_ay_sem(code, ay_sem):
'''
Get the quota of a mod in a target fixed AY/Sem (if any)
'''
number_of_attempts = 0
- 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 load_fixed_mounting_plan
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def load_fixed_mounting_plan(self, module_code):
'''
Loads the fixed mounting plan of the single module
'''
fixed_mounting_and_quota = model.get_fixed_mounting_and_quota(module_code)
- 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 highlightErrorFieldsPreclusion
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function highlightErrorFieldsPreclusion(data) {
var modulesWithErrors = data;
var rows = document.getElementsByTagName("tbody")[0].children;
var message_start = "<p><b>";
- 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"