mirror of https://github.com/Sonarr/Sonarr
use Id instead of time to sort logs to take advantage of built in index.
This commit is contained in:
parent
add4c38589
commit
aa2c96ec7d
|
@ -17,6 +17,12 @@ namespace NzbDrone.Api.Logs
|
|||
private PagingResource<LogResource> GetLogs(PagingResource<LogResource> pagingResource)
|
||||
{
|
||||
var pageSpec = pagingResource.InjectTo<PagingSpec<Log>>();
|
||||
|
||||
if (pageSpec.SortKey == "time")
|
||||
{
|
||||
pageSpec.SortKey = "id";
|
||||
}
|
||||
|
||||
return ApplyToPage(_logService.Paged, pageSpec);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue