mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-11-15 18:08:53 -07:00
updated nuget
This commit is contained in:
parent
90d4f9a6fd
commit
e0f46bb91e
@ -246,13 +246,13 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
var fields = new List<ItemFields>();
|
||||
|
||||
view.BackdropItems = gamesWithBackdrops
|
||||
.Randomize("backdrop")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
.ToList();
|
||||
|
||||
view.SpotlightItems = gamesWithBackdrops
|
||||
.Randomize("spotlight")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
.ToList();
|
||||
@ -294,7 +294,7 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
var seriesWithBestBackdrops = FilterItemsForBackdropDisplay(seriesWithBackdrops).ToList();
|
||||
|
||||
view.BackdropItems = seriesWithBestBackdrops
|
||||
.Randomize("backdrop")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.AsParallel()
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
@ -336,7 +336,7 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
}
|
||||
|
||||
spotlightSeries = spotlightSeries
|
||||
.Randomize("spotlight")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.ToList();
|
||||
|
||||
@ -374,8 +374,11 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
|
||||
view.SeriesIdsInProgress = nextUpEpisodes.Select(i => i.Series.Id.ToString("N")).ToList();
|
||||
|
||||
// Avoid implicitly captured closure
|
||||
var currentUser1 = user;
|
||||
|
||||
var ownedEpisodes = series
|
||||
.SelectMany(i => i.GetRecursiveChildren(user, j => j.LocationType != LocationType.Virtual))
|
||||
.SelectMany(i => i.GetRecursiveChildren(currentUser1, j => j.LocationType != LocationType.Virtual))
|
||||
.OfType<Episode>()
|
||||
.ToList();
|
||||
|
||||
@ -439,7 +442,7 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
var itemsWithTopBackdrops = FilterItemsForBackdropDisplay(itemsWithBackdrops).ToList();
|
||||
|
||||
view.BackdropItems = itemsWithTopBackdrops
|
||||
.Randomize("backdrop")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.AsParallel()
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
@ -524,7 +527,7 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
}
|
||||
|
||||
spotlightItems = spotlightItems
|
||||
.Randomize("spotlight")
|
||||
.OrderBy(i => Guid.NewGuid())
|
||||
.Take(10)
|
||||
.ToList();
|
||||
|
||||
@ -559,16 +562,19 @@ namespace MediaBrowser.Api.DefaultTheme
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
.ToList();
|
||||
|
||||
// Avoid implicitly captured closure
|
||||
var currentUserId1 = user.Id;
|
||||
|
||||
view.LatestMovies = movies
|
||||
.OrderByDescending(i => i.DateCreated)
|
||||
.Where(i => !_userDataManager.GetUserData(user.Id, i.GetUserDataKey()).Played)
|
||||
.Where(i => !_userDataManager.GetUserData(currentUserId1, i.GetUserDataKey()).Played)
|
||||
.Take(request.LatestMoviesLimit)
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
.ToList();
|
||||
|
||||
view.LatestTrailers = trailers
|
||||
.OrderByDescending(i => i.DateCreated)
|
||||
.Where(i => !_userDataManager.GetUserData(user.Id, i.GetUserDataKey()).Played)
|
||||
.Where(i => !_userDataManager.GetUserData(currentUserId1, i.GetUserDataKey()).Played)
|
||||
.Take(request.LatestTrailersLimit)
|
||||
.Select(i => _dtoService.GetBaseItemDto(i, fields, user))
|
||||
.ToList();
|
||||
|
@ -294,5 +294,13 @@ namespace MediaBrowser.Controller.Library
|
||||
/// <param name="item">The item.</param>
|
||||
/// <returns>System.String.</returns>
|
||||
string FindCollectionType(BaseItem item);
|
||||
|
||||
/// <summary>
|
||||
/// Saves the metadata.
|
||||
/// </summary>
|
||||
/// <param name="item">The item.</param>
|
||||
/// <param name="updateType">Type of the update.</param>
|
||||
/// <returns>Task.</returns>
|
||||
Task SaveMetadata(BaseItem item, ItemUpdateType updateType);
|
||||
}
|
||||
}
|
@ -12,5 +12,11 @@ namespace MediaBrowser.Controller.Library
|
||||
/// </summary>
|
||||
/// <value>The item.</value>
|
||||
public BaseItem Item { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the item.
|
||||
/// </summary>
|
||||
/// <value>The item.</value>
|
||||
public ItemUpdateType UpdateReason { get; set; }
|
||||
}
|
||||
}
|
||||
|
@ -1312,7 +1312,11 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
{
|
||||
try
|
||||
{
|
||||
ItemUpdated(this, new ItemChangeEventArgs { Item = item });
|
||||
ItemUpdated(this, new ItemChangeEventArgs
|
||||
{
|
||||
Item = item,
|
||||
UpdateReason = updateReason
|
||||
});
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
@ -1377,8 +1381,14 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
/// <param name="item">The item.</param>
|
||||
/// <param name="updateType">Type of the update.</param>
|
||||
/// <returns>Task.</returns>
|
||||
private async Task SaveMetadata(BaseItem item, ItemUpdateType updateType)
|
||||
public async Task SaveMetadata(BaseItem item, ItemUpdateType updateType)
|
||||
{
|
||||
var locationType = item.LocationType;
|
||||
if (locationType == LocationType.Remote || locationType == LocationType.Virtual)
|
||||
{
|
||||
throw new ArgumentException("Only file-system based items can save metadata.");
|
||||
}
|
||||
|
||||
foreach (var saver in _savers.Where(i => i.IsEnabledFor(item, updateType)))
|
||||
{
|
||||
var path = saver.GetSavePath(item);
|
||||
@ -1444,7 +1454,7 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
|
||||
try
|
||||
{
|
||||
|
||||
|
||||
return i.ResolveArgs.PhysicalLocations.Contains(item.Path);
|
||||
}
|
||||
catch (IOException ex)
|
||||
|
@ -2,7 +2,7 @@
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>MediaBrowser.Common.Internal</id>
|
||||
<version>3.0.240</version>
|
||||
<version>3.0.241</version>
|
||||
<title>MediaBrowser.Common.Internal</title>
|
||||
<authors>Luke</authors>
|
||||
<owners>ebr,Luke,scottisafool</owners>
|
||||
@ -12,7 +12,7 @@
|
||||
<description>Contains common components shared by Media Browser Theater and Media Browser Server. Not intended for plugin developer consumption.</description>
|
||||
<copyright>Copyright © Media Browser 2013</copyright>
|
||||
<dependencies>
|
||||
<dependency id="MediaBrowser.Common" version="3.0.240" />
|
||||
<dependency id="MediaBrowser.Common" version="3.0.241" />
|
||||
<dependency id="NLog" version="2.1.0" />
|
||||
<dependency id="ServiceStack.Text" version="3.9.58" />
|
||||
<dependency id="SimpleInjector" version="2.3.6" />
|
||||
|
@ -2,7 +2,7 @@
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>MediaBrowser.Common</id>
|
||||
<version>3.0.240</version>
|
||||
<version>3.0.241</version>
|
||||
<title>MediaBrowser.Common</title>
|
||||
<authors>Media Browser Team</authors>
|
||||
<owners>ebr,Luke,scottisafool</owners>
|
||||
|
@ -2,7 +2,7 @@
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>MediaBrowser.Server.Core</id>
|
||||
<version>3.0.240</version>
|
||||
<version>3.0.241</version>
|
||||
<title>Media Browser.Server.Core</title>
|
||||
<authors>Media Browser Team</authors>
|
||||
<owners>ebr,Luke,scottisafool</owners>
|
||||
@ -12,7 +12,7 @@
|
||||
<description>Contains core components required to build plugins for Media Browser Server.</description>
|
||||
<copyright>Copyright © Media Browser 2013</copyright>
|
||||
<dependencies>
|
||||
<dependency id="MediaBrowser.Common" version="3.0.240" />
|
||||
<dependency id="MediaBrowser.Common" version="3.0.241" />
|
||||
</dependencies>
|
||||
</metadata>
|
||||
<files>
|
||||
|
Loading…
Reference in New Issue
Block a user