pwa: set TTL of push notification to 30 days (#70988)
gitea/combo/pipeline/head Build queued... Details

This commit is contained in:
Benjamin Dauvergne 2024-01-09 16:52:56 +01:00
parent 03361bfbb9
commit 05e615ddc9
1 changed files with 1 additions and 0 deletions

View File

@ -64,6 +64,7 @@ def notification(sender, instance=None, created=False, **kwargs):
data=message,
vapid_private_key=pwa_vapid_private_key,
vapid_claims=claims,
ttl=86400 * 30,
)
except pywebpush.WebPushException as e:
if 'Push failed: 410 Gone' in str(e):