diff options
author | Vitaly Takmazov | 2023-05-19 02:37:30 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2023-05-19 02:37:30 +0300 |
commit | 56c7241c2ff3e62b2f6f8064f985181f4387dd3d (patch) | |
tree | a80ab079ae06ed5a6ccd085e73f44003bf2452aa | |
parent | fc6472d14edf8f45b6c3e6ad8cbb83bd57a0d545 (diff) |
push-notifications: delete fcm tokens failed with `InvalidRegistration`
-rw-r--r-- | vnext/server/sender.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vnext/server/sender.js b/vnext/server/sender.js index db006233..7c72cbf3 100644 --- a/vnext/server/sender.js +++ b/vnext/server/sender.js @@ -71,7 +71,7 @@ export function sendNotification(productionIds, sandboxIds, data) { }); results.filter(r => r.method === 'gcm') .forEach(async r => { - let badTokens = r.message.filter(m => m.errorMsg === 'NotRegistered' || m.errorMsg === 'MismatchSenderId').map(m => { + let badTokens = r.message.filter(m => m.errorMsg === 'NotRegistered' || m.errorMsg === 'MismatchSenderId' || m.errorMsg === 'InvalidRegistration').map(m => { return { 'type': 'fcm', 'token': m.regId }; }); if (badTokens.length > 0) { |