1
0
Fork 0
mirror of https://github.com/binwiederhier/ntfy.git synced 2024-11-22 19:33:27 +01:00

Improve WebPushEnabled conditional display

This commit is contained in:
nimbleghost 2023-06-14 14:33:35 +02:00
parent 67b9d2eaf6
commit e2120bc66d

View file

@ -86,7 +86,7 @@ const Notifications = () => {
<Sound />
<MinPriority />
<DeleteAfter />
{config.enable_web_push && <WebPushEnabled />}
{notifier.pushPossible() && <WebPushEnabled />}
</PrefGroup>
</Card>
);
@ -242,10 +242,6 @@ const WebPushEnabled = () => {
await prefs.setWebPushEnabled(ev.target.value);
};
if (!notifier.pushPossible()) {
return null;
}
return (
<Pref
labelId={labelId}