mirror of
https://github.com/element-hq/synapse.git
synced 2024-11-28 15:08:49 +03:00
Fixup
This commit is contained in:
parent
c9a743d053
commit
3368c1cb0a
1 changed files with 3 additions and 1 deletions
|
@ -547,7 +547,9 @@ class JsonResource(DirectServeJsonResource):
|
|||
|
||||
# Is it synchronous? We'll allow this for now.
|
||||
if isinstance(raw_callback_return, (defer.Deferred, types.CoroutineType)):
|
||||
callback_return = await raw_callback_return
|
||||
callback_return = await measure_coroutine(
|
||||
request.request_metrics.name, raw_callback_return
|
||||
)
|
||||
else:
|
||||
callback_return = raw_callback_return
|
||||
|
||||
|
|
Loading…
Reference in a new issue