From 3d8b836e22981063d0396e04eefcb10fdec600ee Mon Sep 17 00:00:00 2001 From: Dominic Gannaway Date: Thu, 9 May 2019 17:01:18 +0100 Subject: [PATCH] Event API: ensure we pop context for event system fibers (#15599) --- packages/react-reconciler/src/ReactFiberUnwindWork.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/react-reconciler/src/ReactFiberUnwindWork.js b/packages/react-reconciler/src/ReactFiberUnwindWork.js index c0c67c2536e1b..c1d068c6796d2 100644 --- a/packages/react-reconciler/src/ReactFiberUnwindWork.js +++ b/packages/react-reconciler/src/ReactFiberUnwindWork.js @@ -499,6 +499,12 @@ function unwindInterruptedWork(interruptedWork: Fiber) { case ContextProvider: popProvider(interruptedWork); break; + case EventComponent: + case EventTarget: + if (enableEventAPI) { + popHostContext(interruptedWork); + } + break; default: break; }