1
0
mirror of https://github.com/checktheroads/hyperglass synced 2024-05-11 05:55:08 +00:00

fix issue where if greeting is disabled, the page reloads

This commit is contained in:
thatmattlove
2024-02-17 15:59:22 -05:00
parent 52f910f616
commit cbaf102015

View File

@ -24,10 +24,13 @@ export const Greeting = (props: ModalContentProps): JSX.Element => {
const color = useOpposingColor(bg);
useEffect(() => {
if (!web.greeting.enable && !web.greeting.required) {
ack(true, false);
}
if (!isAck && web.greeting.enable) {
open();
}
}, [isAck, open, web.greeting.enable]);
}, [isAck, open, web.greeting.enable, web.greeting.required, ack]);
return (
<Modal
size="lg"