diff --git a/js/modules/k6/browser/common/http.go b/js/modules/k6/browser/common/http.go index 557ddb33bf8..f83f245a66d 100644 --- a/js/modules/k6/browser/common/http.go +++ b/js/modules/k6/browser/common/http.go @@ -153,7 +153,7 @@ func NewRequest(ctx context.Context, logger *log.Logger, rp NewRequestParams) (* requestID: ev.RequestID, method: ev.Request.Method, postDataEntries: pd, - resourceType: ev.Type.String(), + resourceType: validateResourceType(logger, ev.Type.String()), isNavigationRequest: isNavigationRequest, allowInterception: rp.allowInterception, interceptionID: rp.interceptionID,