mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2025-01-03 17:52:31 +01:00
Merge branch 'master' of https://github.com/LiaungYip/python-telegram-bot into LiaungYip-master
This commit is contained in:
commit
af3e8c6440
2 changed files with 3 additions and 1 deletions
|
@ -18,6 +18,7 @@ The following wonderful people contributed directly or indirectly to this projec
|
||||||
- `jh0ker <https://github.com/jh0ker>`_
|
- `jh0ker <https://github.com/jh0ker>`_
|
||||||
- `JRoot3D <https://github.com/JRoot3D>`_
|
- `JRoot3D <https://github.com/JRoot3D>`_
|
||||||
- `jlmadurga <https://github.com/jlmadurga>`_
|
- `jlmadurga <https://github.com/jlmadurga>`_
|
||||||
|
- `Li-aung Yip <https://github.com/LiaungYip>`_
|
||||||
- `macrojames <https://github.com/macrojames>`_
|
- `macrojames <https://github.com/macrojames>`_
|
||||||
- `naveenvhegde <https://github.com/naveenvhegde>`_
|
- `naveenvhegde <https://github.com/naveenvhegde>`_
|
||||||
- `njittam <https://github.com/njittam>`_
|
- `njittam <https://github.com/njittam>`_
|
||||||
|
|
|
@ -213,7 +213,8 @@ class ConversationHandler(Handler):
|
||||||
|
|
||||||
def update_state(self, new_state, key):
|
def update_state(self, new_state, key):
|
||||||
if new_state == self.END:
|
if new_state == self.END:
|
||||||
del self.conversations[key]
|
if key in self.conversations:
|
||||||
|
del self.conversations[key]
|
||||||
|
|
||||||
elif isinstance(new_state, Promise):
|
elif isinstance(new_state, Promise):
|
||||||
self.conversations[key] = (self.conversations[key], new_state)
|
self.conversations[key] = (self.conversations[key], new_state)
|
||||||
|
|
Loading…
Reference in a new issue