Skip to content

Commit 306da3a

Browse files
Gido Mandersclaude
andcommitted
fix: Add service to useEffect dependency array
Resolves react-hooks/exhaustive-deps warning in useAuthentication. The service is a stable singleton so this has no behavioral change. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent a346c27 commit 306da3a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/hooks.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ export function useAuthentication<User>(): AuthenticationState<User> {
2929
return () => {
3030
service.unsubscribe(subscriber);
3131
};
32-
}, []);
32+
}, [service]);
3333

3434
return state;
3535
}

0 commit comments

Comments
 (0)