Skip to content

Commit

Permalink
Remove wait in event loop
Browse files Browse the repository at this point in the history
  • Loading branch information
Trung Tran committed Jun 20, 2024
1 parent 6d02edc commit 061be92
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Jint/JsValueExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -652,8 +652,7 @@ public static JsValue UnwrapIfPromise(this JsValue value)
var engine = promise.Engine;
var completedEvent = promise.CompletedEvent;
engine.RunAvailableContinuations();
engine.AddToEventLoop(completedEvent.Wait);
engine.RunAvailableContinuations();
completedEvent.Wait();
switch (promise.State)
{
case PromiseState.Pending:
Expand Down

0 comments on commit 061be92

Please sign in to comment.