Skip to content

Also refresh cache on update

CodeScene Delta Analysis / CodeScene Cloud Delta Analysis (release/13.6) succeeded Dec 13, 2024 in 51s

CodeScene PR Check

Code Health Quality Gates: OK

Change in average Code Health of affected files: +0.02 (6.85 -> 6.87)

  • Improving Code Health: 2 findings(s) ✅

View detailed results in CodeScene

Details

✅ Improving Code Health:

  • Low Cohesion MemberRepository.cs
  • Primitive Obsession MemberRepository.cs

Annotations

Check notice on line 1 in src/Umbraco.Infrastructure/Persistence/Repositories/Implement/MemberRepository.cs

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (release/13.6)

✅ Getting better: Low Cohesion

The number of different responsibilities decreases from 7 to 6, threshold = 3. Cohesion is calculated using the LCOM4 metric. Low cohesion means that the module/class has multiple unrelated responsibilities, doing too many things and breaking the Single Responsibility Principle.

Check notice on line 848 in src/Umbraco.Infrastructure/Persistence/Repositories/Implement/MemberRepository.cs

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (release/13.6)

ℹ Getting worse: Complex Method

PersistUpdatedItem already has high cyclomatic complexity, and now it increases in Lines of Code from 101 to 102. This function has many conditional statements (e.g. if, for, while), leading to lower code health. Avoid adding more conditionals and code to it without refactoring.

Check notice on line 1 in src/Umbraco.Infrastructure/Persistence/Repositories/Implement/MemberRepository.cs

See this annotation in the file changed.

@codescene-delta-analysis codescene-delta-analysis / CodeScene Cloud Delta Analysis (release/13.6)

✅ Getting better: Primitive Obsession

The ratio of primitive types in function arguments decreases from 40.00% to 39.22%, threshold = 30.0%. The functions in this file have too many primitive types (e.g. int, double, float) in their function argument lists. Using many primitive types lead to the code smell Primitive Obsession. Avoid adding more primitive arguments.