feat: run staticcheck during build and fix errors
This commit was merged in pull request #285.
This commit is contained in:
@@ -61,7 +61,7 @@ func NewWorkoutDto(rowId string, date string, workoutType string, sets string, r
|
||||
}
|
||||
|
||||
var (
|
||||
ErrInputValues = errors.New("Invalid input values")
|
||||
ErrInputValues = errors.New("invalid input values")
|
||||
)
|
||||
|
||||
func (service WorkoutServiceImpl) AddWorkout(user *User, workoutDto *WorkoutDto) (*WorkoutDto, error) {
|
||||
@@ -125,15 +125,6 @@ func (service WorkoutServiceImpl) GetWorkouts(user *User) ([]*WorkoutDto, error)
|
||||
return workoutsDto, nil
|
||||
}
|
||||
|
||||
func renderDateStr(date string) (string, error) {
|
||||
t, err := time.Parse("2006-01-02 15:04:05-07:00", date)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
||||
return renderDate(t), nil
|
||||
}
|
||||
|
||||
func renderDate(date time.Time) string {
|
||||
return date.Format("2006-01-02")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user