From ee637e8fecbcefe429babbbbd1325bce7c3fe991 Mon Sep 17 00:00:00 2001 From: Bond-009 Date: Mon, 2 Sep 2019 08:19:29 +0200 Subject: Fix warnings, improve performance (#1665) * Fix warnings, improve performance `QueryResult.Items` is now a `IReadOnlyList` so we don't need to allocate a new `Array` when we have a `List` (and `Items` shouldn't need to be mutable anyway) * Update Providers .csproj to latest C# * Remove extra newline from DtoService.cs * Remove extra newline from UserLibraryService.cs --- MediaBrowser.Controller/Entities/TV/Episode.cs | 7 +++++-- MediaBrowser.Controller/Entities/TV/Series.cs | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) (limited to 'MediaBrowser.Controller/Entities/TV') diff --git a/MediaBrowser.Controller/Entities/TV/Episode.cs b/MediaBrowser.Controller/Entities/TV/Episode.cs index fb29c07b0d..e67c00fed9 100644 --- a/MediaBrowser.Controller/Entities/TV/Episode.cs +++ b/MediaBrowser.Controller/Entities/TV/Episode.cs @@ -23,8 +23,11 @@ namespace MediaBrowser.Controller.Entities.TV RemoteTrailerIds = Array.Empty(); } - public Guid[] LocalTrailerIds { get; set; } - public Guid[] RemoteTrailerIds { get; set; } + /// + public IReadOnlyList LocalTrailerIds { get; set; } + + /// + public IReadOnlyList RemoteTrailerIds { get; set; } /// /// Gets the season in which it aired. diff --git a/MediaBrowser.Controller/Entities/TV/Series.cs b/MediaBrowser.Controller/Entities/TV/Series.cs index 1aacc13c9a..a50da9b0a0 100644 --- a/MediaBrowser.Controller/Entities/TV/Series.cs +++ b/MediaBrowser.Controller/Entities/TV/Series.cs @@ -46,8 +46,11 @@ namespace MediaBrowser.Controller.Entities.TV [IgnoreDataMember] public override bool SupportsPeople => true; - public Guid[] LocalTrailerIds { get; set; } - public Guid[] RemoteTrailerIds { get; set; } + /// + public IReadOnlyList LocalTrailerIds { get; set; } + + /// + public IReadOnlyList RemoteTrailerIds { get; set; } /// /// airdate, dvd or absolute -- cgit v1.2.3