lol
thread.run() runs it locally thread.start() runs it in a thread
This commit is contained in:
parent
5ee7041e20
commit
dc7e70ae8d
|
@ -34,7 +34,7 @@ class BrotliCache(object):
|
|||
lock_key = 'brotlicache:lock:{}'.format(digest)
|
||||
if self.redis.set(lock_key, 1, nx=True, ex=10):
|
||||
t = Thread(target=self.compress, args=(cache_key, lock_key, body))
|
||||
t.run()
|
||||
t.start()
|
||||
|
||||
return response
|
||||
|
||||
|
|
Loading…
Reference in New Issue