[chore] format code
This commit is contained in:
parent
a1f801c1d2
commit
36ae86fe6a
1 changed files with 5 additions and 7 deletions
|
@ -112,9 +112,7 @@ class VisibilityEnum(str, enum.Enum):
|
||||||
DIRECT = "direct"
|
DIRECT = "direct"
|
||||||
|
|
||||||
|
|
||||||
def handle_visibility(
|
def handle_visibility(ap_object: dict) -> VisibilityEnum:
|
||||||
ap_object: dict
|
|
||||||
) -> VisibilityEnum:
|
|
||||||
to = ap_object.get("to", [])
|
to = ap_object.get("to", [])
|
||||||
cc = ap_object.get("cc", [])
|
cc = ap_object.get("cc", [])
|
||||||
if AS_PUBLIC in to:
|
if AS_PUBLIC in to:
|
||||||
|
@ -146,9 +144,9 @@ def wrap_ap_object(ap_object: dict) -> dict:
|
||||||
|
|
||||||
|
|
||||||
async def post(
|
async def post(
|
||||||
url: str,
|
url: str,
|
||||||
payload : dict,
|
payload: dict,
|
||||||
) -> httpx.Response :
|
) -> httpx.Response:
|
||||||
logger.info(f"send post, {payload=}")
|
logger.info(f"send post, {payload=}")
|
||||||
|
|
||||||
async with httpx.AsyncClient() as client:
|
async with httpx.AsyncClient() as client:
|
||||||
|
@ -167,7 +165,7 @@ async def post(
|
||||||
|
|
||||||
|
|
||||||
async def fetch(
|
async def fetch(
|
||||||
url: str,
|
url: str,
|
||||||
) -> dict:
|
) -> dict:
|
||||||
logger.info(f"fetch {url}")
|
logger.info(f"fetch {url}")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue