Retry voice when request failed

This commit is contained in:
Ruben van de Ven 2019-04-16 11:17:04 +02:00
parent 72547ae673
commit 080cd1bcee

View file

@ -51,7 +51,8 @@ class VoiceStorage(object):
if os.path.exists(fn): if os.path.exists(fn):
return fn return fn
if id in self.pendingRequests: if id in self.pendingRequests and not self.pendingRequests[id].is_set():
#: :type self.pendingRequests[id] asyncio.Event
await self.pendingRequests[id].wait() await self.pendingRequests[id].wait()
if os.path.exists(fn): if os.path.exists(fn):
return fn return fn