1
0
Fork 0

Fix some annotations

This commit is contained in:
Joeri de Ruiter 2023-09-13 09:22:53 +02:00
parent a5ede835b2
commit a5cf912ae8
2 changed files with 7 additions and 4 deletions

View file

@ -1,4 +1,5 @@
""" basics for an activitypub serializer """
from __future__ import annotations
from dataclasses import dataclass, fields, MISSING
from json import JSONEncoder
import logging
@ -72,7 +73,9 @@ class ActivityObject:
def __init__(
self,
activity_objects: Optional[list[str, base_model.BookWyrmModel]] = None,
activity_objects: Optional[
dict[str, Union[str, list[str], ActivityObject, base_model.BookWyrmModel]]
] = None,
**kwargs: Any,
):
"""this lets you pass in an object with fields that aren't in the