From 6054389dcf76b150821332d202b834dc2f7296d9 Mon Sep 17 00:00:00 2001 From: kookxiang Date: Tue, 25 Jun 2024 23:05:28 +0800 Subject: [PATCH] trim description which causing it to be rendered in tag --- Jellyfin.Plugin.Bangumi/Model/Episode.cs | 2 +- Jellyfin.Plugin.Bangumi/Model/Subject.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Jellyfin.Plugin.Bangumi/Model/Episode.cs b/Jellyfin.Plugin.Bangumi/Model/Episode.cs index 52b9e34..055bba4 100644 --- a/Jellyfin.Plugin.Bangumi/Model/Episode.cs +++ b/Jellyfin.Plugin.Bangumi/Model/Episode.cs @@ -52,7 +52,7 @@ public class Episode public string? Duration { get; set; } [JsonIgnore] - public string? Description => Configuration.ConvertLineBreaks ? DescriptionRaw?.ReplaceLineEndings(Constants.HtmlLineBreak) : DescriptionRaw; + public string? Description => Configuration.ConvertLineBreaks ? DescriptionRaw?.ReplaceLineEndings(Constants.HtmlLineBreak).TrimStart() : DescriptionRaw; [JsonPropertyName("desc")] public string? DescriptionRaw { get; set; } diff --git a/Jellyfin.Plugin.Bangumi/Model/Subject.cs b/Jellyfin.Plugin.Bangumi/Model/Subject.cs index 2914485..b97fde4 100644 --- a/Jellyfin.Plugin.Bangumi/Model/Subject.cs +++ b/Jellyfin.Plugin.Bangumi/Model/Subject.cs @@ -37,7 +37,7 @@ public class Subject public string? ChineseNameRaw { get; set; } [JsonIgnore] - public string? Summary => Configuration.ConvertLineBreaks ? SummaryRaw?.ReplaceLineEndings(Constants.HtmlLineBreak) : SummaryRaw; + public string? Summary => Configuration.ConvertLineBreaks ? SummaryRaw?.ReplaceLineEndings(Constants.HtmlLineBreak).TrimStart() : SummaryRaw; [JsonPropertyName("summary")] public string? SummaryRaw { get; set; }