From 19bfa3e4d6e467acd8ba4c9387a80f1ce4ff14fb Mon Sep 17 00:00:00 2001 From: Karl Date: Thu, 17 Jul 2025 17:49:50 +0100 Subject: [PATCH] another try --- routes/api.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/routes/api.py b/routes/api.py index 748b131..61a79aa 100644 --- a/routes/api.py +++ b/routes/api.py @@ -157,8 +157,8 @@ def vapid_public_key(): # Join the split lines to remove all whitespace and newlines base64_key = "".join(match.group(1).split()) - # Convert to URL-safe base64 for the PushManager API - url_safe_key = base64_key.replace('+', '-').replace('/', '_') + # Convert to URL-safe base64 and remove padding for the PushManager API + url_safe_key = base64_key.replace('+', '-').replace('/', '_').rstrip('=') return jsonify({"public_key": url_safe_key})