mirror of https://git.sr.ht/~tsileo/microblog.pub
Compare commits
2 Commits
94d14fbef3
...
4045902068
Author | SHA1 | Date |
---|---|---|
Thomas Sileo | 4045902068 | |
Thomas Sileo | 20109b45da |
|
@ -189,8 +189,11 @@ async def admin_new(
|
||||||
content += f"{in_reply_to_object.actor.handle} "
|
content += f"{in_reply_to_object.actor.handle} "
|
||||||
for tag in in_reply_to_object.tags:
|
for tag in in_reply_to_object.tags:
|
||||||
if tag.get("type") == "Mention" and tag["name"] != LOCAL_ACTOR.handle:
|
if tag.get("type") == "Mention" and tag["name"] != LOCAL_ACTOR.handle:
|
||||||
|
try:
|
||||||
mentioned_actor = await fetch_actor(db_session, tag["href"])
|
mentioned_actor = await fetch_actor(db_session, tag["href"])
|
||||||
content += f"{mentioned_actor.handle} "
|
content += f"{mentioned_actor.handle} "
|
||||||
|
except Exception:
|
||||||
|
logger.exception(f"Failed to lookup {mentioned_actor}")
|
||||||
|
|
||||||
# Copy the content warning if any
|
# Copy the content warning if any
|
||||||
if in_reply_to_object.summary:
|
if in_reply_to_object.summary:
|
||||||
|
|
|
@ -11,8 +11,8 @@
|
||||||
<ul class="h-feed" id="articles">
|
<ul class="h-feed" id="articles">
|
||||||
<data class="p-name" value="{{ local_actor.display_name}}'s articles"></data>
|
<data class="p-name" value="{{ local_actor.display_name}}'s articles"></data>
|
||||||
{% for outbox_object in objects %}
|
{% for outbox_object in objects %}
|
||||||
<li>
|
<li class="h-entry">
|
||||||
<span class="muted">{{ outbox_object.ap_published_at.strftime("%b %d, %Y") }}</span> <a href="{{ outbox_object.url }}">{{ outbox_object.name }}</a>
|
<time class="muted dt-published" datetime="{{ outbox_object.ap_published_at.isoformat() }}">{{ outbox_object.ap_published_at.strftime("%b %d, %Y") }}</time> <a href="{{ outbox_object.url }}" class="u-url u-uid p-name">{{ outbox_object.name }}</a>
|
||||||
</li>
|
</li>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ul>
|
</ul>
|
||||||
|
|
Loading…
Reference in New Issue