Skip to content

Commit e3d4139

Browse files
committed
[MERGE #5703 @sigatrev] fix CallInstanceFunction with non-RecycableObject thisArgs
Merge pull request #5703 from sigatrev:fixCallInstanceFunction The conditions checked in the beginning of this function were originally setup for more limited use cases. Since it is now used to call user callbacks with a user-provided thisArg, we need to allow any arguments to be passed as thisArg.
2 parents 1f6cd8e + 572d0ac commit e3d4139

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Runtime/Library/EngineInterfaceObject.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ namespace Js
425425
{
426426
EngineInterfaceObject_CommonFunctionProlog(function, callInfo);
427427

428-
if (callInfo.Count < 3 || !JavascriptConversion::IsCallable(args.Values[1]) || !RecyclableObject::Is(args.Values[2]))
428+
if (callInfo.Count < 3 || !JavascriptConversion::IsCallable(args.Values[1]))
429429
{
430430
return scriptContext->GetLibrary()->GetUndefined();
431431
}

0 commit comments

Comments
 (0)