Skip to content

Commit 55664c6

Browse files
author
joshuakgoldberg
committed
Also returning in the warnings
1 parent 05e984a commit 55664c6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/react/src/ReactHooks.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ export function useEffect(
9999
create != null,
100100
'useEffect must be called with a create function, but null or undefined was passed.',
101101
);
102+
return;
102103
}
103104

104105
return dispatcher.useEffect(create, inputs);
@@ -115,6 +116,7 @@ export function useLayoutEffect(
115116
create != null,
116117
'useLayoutEffect must be called with a create function, but null or undefined was passed.',
117118
);
119+
return;
118120
}
119121

120122
return dispatcher.useLayoutEffect(create, inputs);

0 commit comments

Comments
 (0)