binhonglee/GlobeTrotte

View on GitHub
src/turbine/database/tripdb.go

Summary

Maintainability
A
2 hrs
Test Coverage

Function updateDay has 63 lines of code (exceeds 50 allowed). Consider refactoring.
Open

func updateDay(
    updatedDay *wings.Day, createOnNonExist bool,
) bool {
    existingDay := fetchDay(int64(updatedDay.ID))
    if updatedDay.ID == -1 || existingDay.ID != updatedDay.ID {
Severity: Minor
Found in src/turbine/database/tripdb.go - About 1 hr to fix

    Function updateDay has 6 return statements (exceeds 4 allowed).
    Open

    func updateDay(
        updatedDay *wings.Day, createOnNonExist bool,
    ) bool {
        existingDay := fetchDay(int64(updatedDay.ID))
        if updatedDay.ID == -1 || existingDay.ID != updatedDay.ID {
    Severity: Major
    Found in src/turbine/database/tripdb.go - About 40 mins to fix

      There are no issues that match your filters.

      Category
      Status