diff --git a/services/reward/serial.go b/services/reward/serial.go index a4679ebd4..a1e3d4c7e 100644 --- a/services/reward/serial.go +++ b/services/reward/serial.go @@ -21,7 +21,7 @@ func GetSerialNoByRedis() (string, error) { redis_client.Expire(redis_key.RewardSerialCounter(now), 2*time.Minute) } //when the counter n exceeds 1000, the length of the serial number will become longer - if n > 1000 { + if n >= 1000 { return now.Format("200601021504") + fmt.Sprintf("%d", n) + fmt.Sprint(rand.Intn(10)), nil } return now.Format("200601021504") + fmt.Sprintf("%03d", n) + fmt.Sprint(rand.Intn(10)), nil