mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-11 20:56:32 +00:00
add sync error handling
This commit is contained in:
@@ -515,8 +515,14 @@ namespace Emby.Server.Implementations.Sync
|
||||
|
||||
jobItem.Progress = 0;
|
||||
|
||||
var syncOptions = _config.GetSyncOptions();
|
||||
var job = _syncManager.GetJob(jobItem.JobId);
|
||||
if (job == null)
|
||||
{
|
||||
_logger.Error("Job not found. Cannot complete the sync job.");
|
||||
await _syncManager.CancelJobItem(jobItem.Id).ConfigureAwait(false);
|
||||
return;
|
||||
}
|
||||
|
||||
var user = _userManager.GetUserById(job.UserId);
|
||||
if (user == null)
|
||||
{
|
||||
@@ -552,6 +558,8 @@ namespace Emby.Server.Implementations.Sync
|
||||
}
|
||||
}
|
||||
|
||||
var syncOptions = _config.GetSyncOptions();
|
||||
|
||||
var video = item as Video;
|
||||
if (video != null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user