simplify publish function
This commit is contained in:
parent
9741669487
commit
664a2404fa
|
@ -147,7 +147,6 @@ class PublishDispatcher:
|
||||||
check_role,
|
check_role,
|
||||||
kwargs,
|
kwargs,
|
||||||
function_objs)
|
function_objs)
|
||||||
else:
|
|
||||||
try:
|
try:
|
||||||
async with self.pool.acquire() as connection:
|
async with self.pool.acquire() as connection:
|
||||||
await connection.set_type_codec(
|
await connection.set_type_codec(
|
||||||
|
@ -329,8 +328,6 @@ class Dispatcher(register.RegisterDispatcher,
|
||||||
if key in function_obj['arguments']:
|
if key in function_obj['arguments']:
|
||||||
kw[key] = value
|
kw[key] = value
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
kw['risotto_context'] = risotto_context
|
kw['risotto_context'] = risotto_context
|
||||||
returns = await function(self.injected_self[function_obj['module']], **kw)
|
returns = await function(self.injected_self[function_obj['module']], **kw)
|
||||||
if risotto_context.type == 'rpc':
|
if risotto_context.type == 'rpc':
|
||||||
|
|
Loading…
Reference in New Issue