Skip to content

Commit

Permalink
refactor(firebase): use send_each() instead of send_all()
Browse files Browse the repository at this point in the history
The latter is now deprecated: firebase/firebase-admin-python#706

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
  • Loading branch information
akhilnarang committed Jul 17, 2023
1 parent db876eb commit f40b630
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/cron.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ async def fcm_notification_cron(ctx: dict) -> None:
if messages:
app_name = ctx.get("job_id", uuid.uuid4())
app = initialize_app(name=app_name, credential=credentials.Certificate(settings.GOOGLE_APPLICATION_CREDENTIALS))
messaging.send_all(messages=messages, app=app)
messaging.send_each(messages=messages, app=app)
delete_app(app)
logging.info("Sent notification")
else:
Expand Down

0 comments on commit f40b630

Please sign in to comment.