Skip to content

Commit

Permalink
fix(task): cast uptime from int64 to uint64
Browse files Browse the repository at this point in the history
  • Loading branch information
bdeneux committed Dec 21, 2022
1 parent 480a887 commit 993a891
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions app/nemeton/task.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ func (t Task) InProgressAt(at time.Time) bool {

func (t Task) GetUptimeMaxPoints() *uint64 {
if v, ok := t.Params[taskParamUptimeMaxPoints]; ok {
if maxPoints, ok := v.(uint64); ok {
return &maxPoints
if maxPoints, ok := v.(int64); ok {
p := uint64(maxPoints)
return &p
}
}
return nil
Expand Down

0 comments on commit 993a891

Please sign in to comment.