1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2026-04-23 19:41:06 +02:00
Files

22 lines
394 B
Go
Raw Permalink Normal View History

package svg
import (
"net/http"
2025-11-20 01:26:21 +06:00
"github.com/imgproxy/imgproxy/v3/errctx"
)
type (
2025-11-20 01:26:21 +06:00
SanitizeError struct{ *errctx.WrappedError }
)
func newSanitizeError(err error) error {
2025-11-20 01:26:21 +06:00
return SanitizeError{errctx.NewWrappedError(
err,
1,
2025-11-20 01:26:21 +06:00
errctx.WithStatusCode(http.StatusUnprocessableEntity),
errctx.WithPublicMessage("Broken or unsupported SVG image"),
errctx.WithShouldReport(true),
)}
}