Don't double-stringify fcm payloads
This commit is contained in:
parent
8967818fcc
commit
d350f6be9a
@ -276,13 +276,13 @@ export async function sendPushNotification(
|
||||
body: string,
|
||||
token?: string,
|
||||
) {
|
||||
const message = JSON.stringify({
|
||||
const message = {
|
||||
notification: {
|
||||
body,
|
||||
title,
|
||||
},
|
||||
token,
|
||||
});
|
||||
};
|
||||
|
||||
const notifResp = await fetch(
|
||||
"https://fcm.googleapis.com/v1/projects/car-crushers-mobile/messages:send",
|
||||
|
Loading…
x
Reference in New Issue
Block a user