diff --git a/browser/request_mapping.go b/browser/request_mapping.go index 567164e82..942477311 100644 --- a/browser/request_mapping.go +++ b/browser/request_mapping.go @@ -57,11 +57,7 @@ func mapRequest(vu moduleVU, r *common.Request) mapping { return mapResponse(vu, resp), nil }) }, - "size": func() *goja.Promise { - return k6ext.Promise(vu.Context(), func() (any, error) { - return r.Size(), nil - }) - }, + "size": r.Size, "timing": r.Timing, "url": r.URL, }