From 853bfd5f9babb34173bf1a7ae421a7131d163a2b Mon Sep 17 00:00:00 2001 From: Zoe Roux Date: Mon, 29 Jan 2024 00:01:55 +0100 Subject: [PATCH] Fix x-client-id error message --- transcoder/utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/transcoder/utils.go b/transcoder/utils.go index bc3f3901..8dafd3d4 100644 --- a/transcoder/utils.go +++ b/transcoder/utils.go @@ -66,7 +66,7 @@ func SanitizePath(path string) error { func GetClientId(c echo.Context) (string, error) { key := c.Request().Header.Get("X-CLIENT-ID") if key == "" { - return "", errors.New("missing client id. Please specify the X-CLIENT-ID header to a guid constant for the lifetime of the player (but unique per instance)") + return "", echo.NewHTTPError(http.StatusBadRequest, "missing client id. Please specify the X-CLIENT-ID header to a guid constant for the lifetime of the player (but unique per instance)") } return key, nil }