summaryrefslogtreecommitdiffstats
path: root/api/user.go
diff options
context:
space:
mode:
Diffstat (limited to 'api/user.go')
-rw-r--r--api/user.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/api/user.go b/api/user.go
index da6a24ab4..483ae67b5 100644
--- a/api/user.go
+++ b/api/user.go
@@ -593,7 +593,7 @@ func createProfileImage(username string, userId string) ([]byte, *model.AppError
h.Write([]byte(userId))
seed := h.Sum32()
- color := colors[int(seed)%len(colors)]
+ color := colors[int64(seed)%int64(len(colors))]
img := image.NewRGBA(image.Rect(0, 0, int(utils.Cfg.ImageSettings.ProfileWidth), int(utils.Cfg.ImageSettings.ProfileHeight)))
draw.Draw(img, img.Bounds(), &image.Uniform{color}, image.ZP, draw.Src)