diff --git a/modules/commands/__init__.py b/modules/commands/__init__.py index c7d0ace0..46f79ab3 100644 --- a/modules/commands/__init__.py +++ b/modules/commands/__init__.py @@ -127,7 +127,7 @@ class Module(ModuleManager.BaseModule): returns = [] if requests: for request, request_args in requests: - returns.append(event_hook.on(request).call_unsafe_for_result( + returns.append(event_hook.on(request).call_for_result_unsafe( **kwargs, request_args=request_args)) else: returns = event_hook.call_unsafe(**kwargs) diff --git a/modules/rest_api.py b/modules/rest_api.py index 4dc742cd..a436bff3 100644 --- a/modules/rest_api.py +++ b/modules/rest_api.py @@ -73,7 +73,7 @@ class Handler(http.server.BaseHTTPRequestHandler): try: event_response = _bot.trigger(lambda: _events.on("api").on(method).on( - endpoint).call_unsafe_for_result(params=params, + endpoint).call_for_result_unsafe(params=params, path=args, data=data, headers=headers)) except Exception as e: _log.error("failed to call API endpoint \"%s\"",