18F/cg-dashboard

View on GitHub
helpers/settings.go

Summary

Maintainability
A
2 hrs
Test Coverage

Method Settings.InitSettings has 71 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func (s *Settings) InitSettings(envVars *env.VarSet) (retErr error) {
    defer func() {
        // While .MustString() is convenient in readability below, we'd prefer
        // to convert this to an error for upstream callers.
        if r := recover(); r != nil {
Severity: Minor
Found in helpers/settings.go - About 1 hr to fix

    Method Settings.InitSettings has 6 return statements (exceeds 4 allowed).
    Open

    func (s *Settings) InitSettings(envVars *env.VarSet) (retErr error) {
        defer func() {
            // While .MustString() is convenient in readability below, we'd prefer
            // to convert this to an error for upstream callers.
            if r := recover(); r != nil {
    Severity: Major
    Found in helpers/settings.go - About 40 mins to fix

      There are no issues that match your filters.

      Category
      Status