v0.12.7 FCM bug fixes
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "rosterchirp-backend",
|
||||
"version": "0.12.6",
|
||||
"version": "0.12.7",
|
||||
"description": "RosterChirp backend server",
|
||||
"main": "src/index.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -47,6 +47,10 @@ async function sendPushToUser(schema, userId, payload) {
|
||||
groupId: payload.groupId ? String(payload.groupId) : '',
|
||||
},
|
||||
android: { priority: 'high' },
|
||||
apns: {
|
||||
headers: { 'apns-priority': '10' },
|
||||
payload: { aps: { contentAvailable: true } },
|
||||
},
|
||||
webpush: { headers: { Urgency: 'high' } },
|
||||
});
|
||||
} catch (err) {
|
||||
@@ -141,6 +145,10 @@ router.post('/test', authMiddleware, async (req, res) => {
|
||||
const message = {
|
||||
token: sub.fcm_token,
|
||||
android: { priority: 'high' },
|
||||
apns: {
|
||||
headers: { 'apns-priority': '10' },
|
||||
payload: { aps: { contentAvailable: true } },
|
||||
},
|
||||
webpush: { headers: { Urgency: 'high' } },
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user