From 031cc30c17bc81b7e6f06814d4714e729b1e3e53 Mon Sep 17 00:00:00 2001 From: Mihail Stoykov <312246+mstoykov@users.noreply.github.com> Date: Sat, 26 Oct 2024 11:14:57 +0300 Subject: [PATCH] Update js/modules/require_impl.go MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Joan López de la Franca Beltran <5459617+joanlopez@users.noreply.github.com> --- js/modules/require_impl.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/modules/require_impl.go b/js/modules/require_impl.go index 21df9644e9a..4663d66d28e 100644 --- a/js/modules/require_impl.go +++ b/js/modules/require_impl.go @@ -201,7 +201,7 @@ func getPreviousRequiringFile(vu VU) (string, error) { // sets the provided promise in such way as to ignore falures // this is mostly needed as failures are handled separately and we do not want those to lead to stopping the event loop func promisesThenIgnore(rt *sobek.Runtime, promise *sobek.Promise) { - cal, _ := sobek.AssertFunction(rt.ToValue(promise).ToObject(rt).Get("then")) + call, _ := sobek.AssertFunction(rt.ToValue(promise).ToObject(rt).Get("then")) handler := rt.ToValue(func(_ sobek.Value) {}) - _, _ = cal(rt.ToValue(promise), handler, handler) + _, _ = call(rt.ToValue(promise), handler, handler) }