Description
The RegisterModel function in internal/adminpanel/app.go has a cyclomatic complexity of 84, far exceeding the recommended standard.
Location
- File:
internal/adminpanel/app.go
- Line number(s): 34
Expected Style
Adherence to a cyclomatic complexity of 15 or below according to project standards.
Current Style
The current complexity of 84 suggests excessive decision-making processes embedded in the function.
Additional Context
High complexity indicates a potential need for significant design change.
Suggestions for Improvement
Refactoring could involve splitting the logic across multiple functions, simplifying loops, or using early returns to reduce nesting.
Environment
All development environments
Checklist
Description
The
RegisterModelfunction ininternal/adminpanel/app.gohas a cyclomatic complexity of 84, far exceeding the recommended standard.Location
internal/adminpanel/app.goExpected Style
Adherence to a cyclomatic complexity of 15 or below according to project standards.
Current Style
The current complexity of 84 suggests excessive decision-making processes embedded in the function.
Additional Context
High complexity indicates a potential need for significant design change.
Suggestions for Improvement
Refactoring could involve splitting the logic across multiple functions, simplifying loops, or using early returns to reduce nesting.
Environment
All development environments
Checklist