Fix 'setting.Get' runaway calls

## Issue
60 setting.Get calls spiked since October

It was called 24 times per livestream page load.

## Notes
The effect was intended to be a one-time effect, but the dependency was changed in 2f4dedfb
This commit is contained in:
infinite-persistence 2021-10-14 16:09:28 +08:00
parent 4aaa26794b
commit 2c3c0e8f1d
No known key found for this signature in database
GPG key ID: B9C3252EDC3D0AA0

View file

@ -407,7 +407,7 @@ export function CommentCreate(props: Props) {
if (!channelSettings && channelId) { if (!channelSettings && channelId) {
doFetchCreatorSettings(channelId); doFetchCreatorSettings(channelId);
} }
}, [channelId, channelSettings, doFetchCreatorSettings]); }, []); // eslint-disable-line react-hooks/exhaustive-deps
// Notifications: Fetch top-level comments to identify if it has been deleted and can reply to it // Notifications: Fetch top-level comments to identify if it has been deleted and can reply to it
React.useEffect(() => { React.useEffect(() => {