1
0
Fork 0
mirror of https://github.com/Radarr/Radarr synced 2025-01-03 13:54:29 +00:00

Fixed: Avoid Sqlite Error when all profiles have lowest quality cutoff

(cherry picked from commit  f05e109b50cca496e7b42e2833eff161a43e12f4)
This commit is contained in:
Qstick 2023-01-26 09:27:58 +00:00 committed by Robin Dadswell
parent ce031124c7
commit 87d59d12a4

View file

@ -1,6 +1,7 @@
using System.Collections.Generic;
using System.Linq;
using NLog;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Datastore;
using NzbDrone.Core.Profiles;
using NzbDrone.Core.Qualities;
@ -41,6 +42,13 @@ public PagingSpec<Movie> MoviesWhereCutoffUnmet(PagingSpec<Movie> pagingSpec)
}
}
if (qualitiesBelowCutoff.Empty())
{
pagingSpec.Records = new List<Movie>();
return pagingSpec;
}
return _movieRepository.MoviesWhereCutoffUnmet(pagingSpec, qualitiesBelowCutoff);
}
}