From 45c6978bc397691b22db0360b16b19979eac7dce Mon Sep 17 00:00:00 2001 From: Andrew Godwin Date: Fri, 16 Dec 2022 16:38:52 -0700 Subject: User admin and LD schema fixes --- activities/models/post.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activities/models') diff --git a/activities/models/post.py b/activities/models/post.py index b5821f7..e8698d3 100644 --- a/activities/models/post.py +++ b/activities/models/post.py @@ -659,7 +659,7 @@ class Post(StatorModel): if update or created: post.content = data["content"] post.summary = data.get("summary") - post.sensitive = data.get("as:sensitive", False) + post.sensitive = data.get("sensitive", False) post.url = data.get("url") post.published = parse_ld_date(data.get("published")) post.edited = parse_ld_date(data.get("updated")) @@ -670,7 +670,7 @@ class Post(StatorModel): if tag["type"].lower() == "mention": mention_identity = Identity.by_actor_uri(tag["href"], create=True) post.mentions.add(mention_identity) - elif tag["type"].lower() == "as:hashtag": + elif tag["type"].lower() == "hashtag": post.hashtags.append(tag["name"].lower().lstrip("#")) elif tag["type"].lower() == "http://joinmastodon.org/ns#emoji": emoji = Emoji.by_ap_tag(post.author.domain, tag, create=True) -- cgit v1.2.3