From 071bf5e93a36e0c962c102f8b9f1434c18963c7c Mon Sep 17 00:00:00 2001 From: Igor Sheludko Date: Mon, 24 Jun 2024 10:42:18 +0200 Subject: [PATCH] src: fix implementation of `PropertySetterCallback` V8 does not allow returning arbitrary values from the interceptor setter callbacks, only a boolean return value is allowed. Since default return value is `true`, it's not even necessary to set the return value on a successful path. Refs: https://crbug.com/348660658 PR-URL: https://github.com/nodejs/node/pull/53576 Reviewed-By: Luigi Pinca Reviewed-By: Chengzhong Wu Reviewed-By: Mohammed Keyvanzadeh --- src/node_contextify.cc | 1 - 1 file changed, 1 deletion(-) diff --git a/src/node_contextify.cc b/src/node_contextify.cc index cc3109ad2111ce..895f7b9d096166 100644 --- a/src/node_contextify.cc +++ b/src/node_contextify.cc @@ -614,7 +614,6 @@ Intercepted ContextifyContext::PropertySetterCallback( // property if (desc_obj->HasOwnProperty(context, env->get_string()).FromMaybe(false) || desc_obj->HasOwnProperty(context, env->set_string()).FromMaybe(false)) { - args.GetReturnValue().Set(value); return Intercepted::kYes; } }