mirror of
https://github.com/Lidarr/Lidarr
synced 2026-05-08 04:21:32 +02:00
Fixed: Escape backticks in discord notifications
(cherry picked from commit 70c74fc1769f2094a14faaa103c49d744534be9f)
This commit is contained in:
parent
50d7550e63
commit
0d10f7d77f
1 changed files with 2 additions and 2 deletions
|
|
@ -514,9 +514,9 @@ private string GetTitle(Artist artist, List<Album> albums)
|
|||
{
|
||||
var albumTitles = string.Join(" + ", albums.Select(e => e.Title));
|
||||
|
||||
var title = $"{artist.Name} - {albumTitles}";
|
||||
var title = $"{artist.Name} - {albumTitles}".Replace("`", "\\`");
|
||||
|
||||
return title.Length > 256 ? $"{title.AsSpan(0, 253)}..." : title;
|
||||
return title.Length > 256 ? $"{title.AsSpan(0, 253).TrimEnd('\\')}..." : title;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue