Showing 736 of 1,140 total issues
Avoid too many return
statements within this method. Open
return false;
Avoid too many return
statements within this method. Open
return Task.FromResult(true);
Avoid too many return
statements within this method. Open
return await AddAndInit(parentView, field, fieldName, await NewStringFieldView(field));
Avoid too many return
statements within this method. Open
if (elemType.IsCastableTo<IDictionary>()) { return JTokenType.Object; }
Avoid too many return
statements within this method. Open
return !oldEnum.Cast<object>().SequenceEqual(newEnum.Cast<object>());
Avoid too many return
statements within this method. Open
return Line.Substring(0, numberOfChars);
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 await AddAndInit(parentView, field, fieldName, await NewListFieldView(field));
Avoid too many return
statements within this method. Open
return true;
Method ArrayDiff
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
private JObject ArrayDiff(JArray left, JArray right)
{
var result = JObject.Parse(@"{ ""_t"": ""a"" }");
int commonHead = 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
Method ExecuteIndex
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
internal override IEnumerable<IndexNode> ExecuteIndex(IndexService indexer, CollectionIndex index)
{
// find first indexNode
var node = indexer.Find(index, _value, true, Query.Ascending);
- 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
Method CleanUp
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
public static void CleanUp(JToken diff) {
if (diff is JArray array) {
for (int i = array.Count - 1; i >= 0; i--) {
var entry = array[i];
if (entry is JProperty property) {
- 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
Method stbi__build_fast_ac
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
private static void stbi__build_fast_ac(short[] fast_ac, stbi__huffman h)
{
var i = 0;
for (i = 0; i < 1 << 9; ++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
Method ArrayHasChanged
has a Cognitive Complexity of 21 (exceeds 20 allowed). Consider refactoring. Open
private bool ArrayHasChanged()
{
int lowerBound = 0;
int upperBound = 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"