1
0
This commit is contained in:
Brendan Abolivier
2021-09-02 11:07:14 +01:00
parent 660837fb9e
commit 0eed68c3ed
2 changed files with 6 additions and 4 deletions

View File

@@ -46,8 +46,7 @@ CHECK_EVENT_FOR_SPAM_CALLBACK = Callable[
]
# FIXME: Callback signature differs from mainline
USER_MAY_INVITE_CALLBACK = Callable[
[str, Optional[str], Optional[dict], str, bool, bool],
Awaitable[bool]
[str, Optional[str], Optional[dict], str, bool, bool], Awaitable[bool]
]
# FIXME: Callback signature differs from mainline
USER_MAY_CREATE_ROOM_CALLBACK = Callable[

View File

@@ -22,7 +22,8 @@ from typing import (
Optional,
Sequence,
Tuple,
overload, Union,
Union,
overload,
)
from typing_extensions import Literal
@@ -630,7 +631,9 @@ def parse_json_object_from_request(
return content
def assert_params_in_dict(body: JsonDict, required: Iterable[Union[str, bytes]]) -> None:
def assert_params_in_dict(
body: JsonDict, required: Iterable[Union[str, bytes]]
) -> None:
absent = []
for k in required:
if k not in body: