Optimze series original name

This commit is contained in:
cxfksword 2023-04-01 11:43:47 +08:00
parent 84e87f9667
commit 07ab257b2b
2 changed files with 2 additions and 2 deletions

View File

@ -51,7 +51,7 @@ namespace Jellyfin.Plugin.MetaShark.Providers
protected readonly IHttpContextAccessor _httpContextAccessor; protected readonly IHttpContextAccessor _httpContextAccessor;
protected Regex regMetaSourcePrefix = new Regex(@"^\[.+\]", RegexOptions.Compiled); protected Regex regMetaSourcePrefix = new Regex(@"^\[.+\]", RegexOptions.Compiled);
protected Regex regSeasonNameSuffix = new Regex(@"\s第[0-9一二三四五六七八九十]+?季$|(?<![0-9a-zA-Z])\d$", RegexOptions.Compiled); protected Regex regSeasonNameSuffix = new Regex(@"\s第[0-9一二三四五六七八九十]+?季$|\sSeason\s\d+?$|(?<![0-9a-zA-Z])\d$", RegexOptions.Compiled);
protected PluginConfiguration config protected PluginConfiguration config
{ {

View File

@ -114,7 +114,7 @@ namespace Jellyfin.Plugin.MetaShark.Providers
{ {
ProviderIds = new Dictionary<string, string> { { DoubanProviderId, subject.Sid }, { Plugin.ProviderId, MetaSource.Douban } }, ProviderIds = new Dictionary<string, string> { { DoubanProviderId, subject.Sid }, { Plugin.ProviderId, MetaSource.Douban } },
Name = seriesName, Name = seriesName,
OriginalTitle = subject.OriginalName, OriginalTitle = RemoveSeasonSubfix(subject.OriginalName),
CommunityRating = subject.Rating, CommunityRating = subject.Rating,
Overview = subject.Intro, Overview = subject.Intro,
ProductionYear = subject.Year, ProductionYear = subject.Year,