From 31211a9436b7073ee054cbc091ce684a9051efec Mon Sep 17 00:00:00 2001 From: Mo Tarbin Date: Mon, 22 Jul 2024 18:43:03 -0400 Subject: Support linux_386 by changing minChores to int64, remove debugging log for getNotification --- internal/chore/handler.go | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'internal/chore') diff --git a/internal/chore/handler.go b/internal/chore/handler.go index 333521a..16c80ef 100644 --- a/internal/chore/handler.go +++ b/internal/chore/handler.go @@ -1097,12 +1097,12 @@ func checkNextAssignee(chore *chModel.Chore, choresHistory []*chModel.ChoreHisto } } - minChores := math.MaxInt64 + var minChores int64 = math.MaxInt64 for assignee, numChores := range assigneeChores { // if this is the first assignee or if the number of // chores assigned to this assignee is less than the current minimum - if numChores < minChores { - minChores = numChores + if int64(numChores) < minChores { + minChores = int64(numChores) // set the next assignee to this assignee nextAssignee = assignee } @@ -1119,12 +1119,13 @@ func checkNextAssignee(chore *chModel.Chore, choresHistory []*chModel.ChoreHisto } // max Int value - minChores := math.MaxInt64 + var minChores int64 = math.MaxInt64 + for assignee, numChores := range assigneeChores { // if this is the first assignee or if the number of // chores completed by this assignee is less than the current minimum - if numChores < minChores { - minChores = numChores + if int64(numChores) < minChores { + minChores = int64(numChores) // set the next assignee to this assignee nextAssignee = assignee } -- cgit