Improve notifications

- Keep track of unread count
 - "follow back" action
This commit is contained in:
Thomas Sileo
2019-07-29 19:36:22 +02:00
parent 2ab59d9476
commit d70c73cad7
9 changed files with 261 additions and 36 deletions

View File

@@ -3,6 +3,7 @@ from datetime import datetime
from datetime import timezone
from dateutil import parser
from little_boxes import activitypub as ap
logger = logging.getLogger(__name__)
@@ -25,3 +26,7 @@ def parse_datetime(s: str) -> datetime:
dt = dt.replace(tzinfo=timezone.utc)
return dt
def now() -> str:
ap.format_datetime(datetime.now(timezone.utc))