feat(chromium): HTTP Bad Request on net::ERR_CONNECTION_REFUSED

This commit is contained in:
Julien Neuhart
2024-07-01 13:40:12 +02:00
parent 84dc57373a
commit f87362ec1b
6 changed files with 144 additions and 4 deletions

View File

@@ -688,5 +688,15 @@ func handleChromiumError(err error, options Options) error {
)
}
if errors.Is(err, ErrConnectionRefused) {
return api.WrapError(
err,
api.NewSentinelHttpError(
http.StatusBadRequest,
"Chromium returned net::ERR_CONNECTION_REFUSED",
),
)
}
return err
}