Don't double-stringify fcm payloads

This commit is contained in:
2023-10-19 16:51:17 -04:00
parent 8967818fcc
commit d350f6be9a

View File

@ -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",