Tweak to avoid property read (#14593)

This commit is contained in:
Brandon Dail 2019-01-14 17:39:27 -08:00 committed by GitHub
parent 0fc1547513
commit 7ad9806d11
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -214,8 +214,9 @@ function throwException(
// attach another listener to flip the boundary back to its normal state.
const thenables: Set<Thenable> = (workInProgress.updateQueue: any);
if (thenables === null) {
workInProgress.updateQueue = (new Set(): any);
workInProgress.updateQueue.add(thenable);
const updateQueue = (new Set(): any);
updateQueue.add(thenable);
workInProgress.updateQueue = updateQueue;
} else {
thenables.add(thenable);
}