Count records before skipping
This commit is contained in:
parent
6b24cc6d1f
commit
2a9474f6e7
|
@ -130,13 +130,13 @@ namespace Jellyfin.Server.Implementations.Devices
|
|||
devices = devices.Where(device => device.AccessToken == query.AccessToken);
|
||||
}
|
||||
|
||||
var count = await devices.CountAsync().ConfigureAwait(false);
|
||||
|
||||
if (query.Skip.HasValue)
|
||||
{
|
||||
devices = devices.Skip(query.Skip.Value);
|
||||
}
|
||||
|
||||
var count = await devices.CountAsync().ConfigureAwait(false);
|
||||
|
||||
if (query.Limit.HasValue)
|
||||
{
|
||||
devices = devices.Take(query.Limit.Value);
|
||||
|
|
Loading…
Reference in New Issue
Block a user