1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2026-06-13 22:32:40 +02:00
Files

20 lines
398 B
Go
Raw Permalink Normal View History

2025-09-11 17:29:43 +03:00
package workers
import (
"net/http"
2026-05-13 18:48:55 +03:00
"github.com/imgproxy/imgproxy/v4/errctx"
)
2025-11-20 01:26:21 +06:00
type TooManyRequestsError struct{ *errctx.TextError }
func newTooManyRequestsError() error {
2025-11-20 01:26:21 +06:00
return TooManyRequestsError{errctx.NewTextError(
"Too many requests",
1,
2025-11-20 01:26:21 +06:00
errctx.WithStatusCode(http.StatusTooManyRequests),
errctx.WithPublicMessage("Too many requests"),
errctx.WithShouldReport(false),
)}
}