Skip to content

Commit e165e44

Browse files
committed
fix: Stop using nullish coalescing
1 parent 787cb85 commit e165e44

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

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)