Replace self defined const StatusTooManyRequests with http.StatusTooManyRequests.

This commit is contained in:
Jianfei Bai 2019-08-12 21:56:20 +08:00
parent 07077a8aa5
commit 2a6e6c9776

View File

@ -30,11 +30,11 @@ import (
)
const (
// DEPRECATED: please use http.StatusTooManyRequests, this will be removed in
// the future version.
// StatusTooManyRequests means the server experienced too many requests within a
// given window and that the client must wait to perform the action again.
StatusTooManyRequests = 429
// DEPRECATED: please use http.StatusTooManyRequests, this will be removed in
// the future version.
StatusTooManyRequests = http.StatusTooManyRequests
)
// StatusError is an error intended for consumption by a REST API server; it can also be