From 95f89beae96ad4b3a91000d41dc286c22c561894 Mon Sep 17 00:00:00 2001 From: Bibo-Joshi <22366557+Bibo-Joshi@users.noreply.github.com> Date: Tue, 12 Jul 2022 22:28:35 +0200 Subject: [PATCH] Updated Concurrency (markdown) --- Concurrency.md | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/Concurrency.md b/Concurrency.md index 8a0fc75..e9c4641 100644 --- a/Concurrency.md +++ b/Concurrency.md @@ -307,14 +307,15 @@ async def transaction(update, context): bank.write_account(target) # 1 - context.dispatcher.run_async( - log_and_notify, - FINISHED_TRANSACTION, - amount, - source_id, - target_id, - chat_id, - 'Done!', + context.application.create_task( + log_and_notify( + FINISHED_TRANSACTION, + amount, + source_id, + target_id, + chat_id, + 'Done!', + ), update=update )