xmidt-org/svalinn

View on GitHub
requestParser/createRecord.go

Summary

Maintainability
A
1 hr
Test Coverage

Method RequestParser.createRecord has 8 return statements (exceeds 4 allowed).
Open

func (r *RequestParser) createRecord(req wrp.Message, rule *rules.Rule, eventType db.EventType) (db.Record, string, error) {
    var (
        err         error
        emptyRecord db.Record
        record      = db.Record{Type: eventType}
Severity: Major
Found in requestParser/createRecord.go - About 50 mins to fix

    Function getBirthDate has 5 return statements (exceeds 4 allowed).
    Open

    func getBirthDate(payload []byte) (time.Time, bool) {
        p := make(map[string]interface{})
        if len(payload) == 0 {
            return time.Time{}, false
        }
    Severity: Major
    Found in requestParser/createRecord.go - About 35 mins to fix

      There are no issues that match your filters.

      Category
      Status