Skip to content

Commit 1645d21

Browse files
authored
fix: Stop using nullish coalescing (#1299)
1 parent 787cb85 commit 1645d21

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: src/act-compat.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import * as React from 'react'
22
import * as DeprecatedReactTestUtils from 'react-dom/test-utils'
33

4-
const reactAct = React.act ?? DeprecatedReactTestUtils.act
4+
const reactAct =
5+
typeof React.act === 'function' ? React.act : DeprecatedReactTestUtils.act
56

67
function getGlobalThis() {
78
/* istanbul ignore else */

0 commit comments

Comments
 (0)