0
0
Fork 0
mirror of https://github.com/healthchecks/healthchecks.git synced 2025-04-08 14:40:05 +00:00

Fix mypy warning

This commit is contained in:
Pēteris Caune 2024-12-16 15:55:36 +02:00
parent ca0d639c6b
commit 3769bf3ede
No known key found for this signature in database
GPG key ID: E28D7679E9A9EDE2

View file

@ -436,14 +436,12 @@ class Slackalike(HttpTransport):
"mrkdwn_in": ["fields"],
"title": f"{name}” is {flip.new_status.upper()}.",
"title_link": check.cloaked_url(),
"text": f"Reason: {flip.reason_long()}." if flip.reason else None,
"fields": fields,
}
],
}
if flip.reason:
result["attachments"][0]["text"] = f"Reason: {flip.reason_long()}."
if check.desc:
fields.add("Description", check.desc, short=False)