mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-05 03:54:58 -04:00
Ensure that a URL exists in the content during push. (#8965)
This fixes an KeyError exception, after this PR the content is just considered unknown.
This commit is contained in:
parent
a7a913918c
commit
4136255d3c
3 changed files with 7 additions and 2 deletions
|
@ -486,7 +486,11 @@ class Mailer:
|
|||
def add_image_message_vars(
|
||||
self, messagevars: Dict[str, Any], event: EventBase
|
||||
) -> None:
|
||||
messagevars["image_url"] = event.content["url"]
|
||||
"""
|
||||
Potentially add an image URL to the message variables.
|
||||
"""
|
||||
if "url" in event.content:
|
||||
messagevars["image_url"] = event.content["url"]
|
||||
|
||||
async def make_summary_text(
|
||||
self,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue