Small refactoring. Finally made use of the type parameter in NadekoTypeReader<T> class

This commit is contained in:
Kwoth
2022-01-31 05:45:51 +01:00
parent 0f36242597
commit 3e0bbd8ada
29 changed files with 130 additions and 128 deletions

View File

@@ -9,7 +9,7 @@ public static class MusicPlaylistExtensions
public static List<MusicPlaylist> GetPlaylistsOnPage(this DbSet<MusicPlaylist> playlists, int num)
{
if (num < 1)
throw new IndexOutOfRangeException();
throw new ArgumentOutOfRangeException(nameof(num));
return playlists.AsQueryable().Skip((num - 1) * 20).Take(20).Include(pl => pl.Songs).ToList();
}