mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-21 17:44:43 +01:00
Cleanup tasks
This commit is contained in:
@@ -36,13 +36,13 @@ namespace Emby.Server.Implementations.ScheduledTasks.Tasks
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="ChapterImagesTask" /> class.
|
||||
/// </summary>
|
||||
/// <param name="logger">The logger.</param>.
|
||||
/// <param name="libraryManager">The library manager.</param>.
|
||||
/// <param name="itemRepo">The item repository.</param>
|
||||
/// <param name="appPaths">The application paths.</param>
|
||||
/// <param name="encodingManager">The encoding manager.</param>
|
||||
/// <param name="fileSystem">The filesystem.</param>
|
||||
/// <param name="localization">The localization manager.</param>
|
||||
/// <param name="logger">Instance of the <see cref="ILogger"/> interface.</param>
|
||||
/// <param name="libraryManager">Instance of the <see cref="ILibraryManager"/> interface.</param>
|
||||
/// <param name="itemRepo">Instance of the <see cref="IItemRepository"/> interface.</param>
|
||||
/// <param name="appPaths">Instance of the <see cref="IApplicationPaths"/> interface.</param>
|
||||
/// <param name="encodingManager">Instance of the <see cref="IEncodingManager"/> interface.</param>
|
||||
/// <param name="fileSystem">Instance of the <see cref="IFileSystem"/> interface.</param>
|
||||
/// <param name="localization">Instance of the <see cref="ILocalizationManager"/> interface.</param>
|
||||
public ChapterImagesTask(
|
||||
ILogger<ChapterImagesTask> logger,
|
||||
ILibraryManager libraryManager,
|
||||
@@ -76,15 +76,15 @@ namespace Emby.Server.Implementations.ScheduledTasks.Tasks
|
||||
/// <inheritdoc />
|
||||
public IEnumerable<TaskTriggerInfo> GetDefaultTriggers()
|
||||
{
|
||||
return new[]
|
||||
{
|
||||
return
|
||||
[
|
||||
new TaskTriggerInfo
|
||||
{
|
||||
Type = TaskTriggerInfo.TriggerDaily,
|
||||
TimeOfDayTicks = TimeSpan.FromHours(2).Ticks,
|
||||
MaxRuntimeTicks = TimeSpan.FromHours(4).Ticks
|
||||
}
|
||||
};
|
||||
];
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -92,18 +92,18 @@ namespace Emby.Server.Implementations.ScheduledTasks.Tasks
|
||||
{
|
||||
var videos = _libraryManager.GetItemList(new InternalItemsQuery
|
||||
{
|
||||
MediaTypes = new[] { MediaType.Video },
|
||||
MediaTypes = [MediaType.Video],
|
||||
IsFolder = false,
|
||||
Recursive = true,
|
||||
DtoOptions = new DtoOptions(false)
|
||||
{
|
||||
EnableImages = false
|
||||
},
|
||||
SourceTypes = new SourceType[] { SourceType.Library },
|
||||
SourceTypes = [SourceType.Library],
|
||||
IsVirtualItem = false
|
||||
})
|
||||
.OfType<Video>()
|
||||
.ToList();
|
||||
.OfType<Video>()
|
||||
.ToList();
|
||||
|
||||
var numComplete = 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user