Bugfixes + Potential iOS Webtoon Reader Fix (#2650)

This commit is contained in:
Joe Milazzo 2024-01-25 11:09:44 -06:00 committed by GitHub
parent 56fa393cf0
commit f660a1cd06
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
25 changed files with 157 additions and 197 deletions

View file

@ -490,6 +490,10 @@ public class SeriesRepository : ISeriesRepository
.ProjectTo<MangaFileDto>(_mapper.ConfigurationProvider)
.ToListAsync();
}
else
{
result.Files = new List<MangaFileDto>();
}
result.Chapters = await _context.Chapter
.Include(c => c.Files)
@ -1930,7 +1934,8 @@ public class SeriesRepository : ISeriesRepository
{
// If there is 0 or 1 rating and that rating is you, return 0 back
var countOfRatingsThatAreUser = await _context.AppUserRating
.Where(r => r.SeriesId == seriesId && r.HasBeenRated).CountAsync(u => u.AppUserId == userId);
.Where(r => r.SeriesId == seriesId && r.HasBeenRated)
.CountAsync(u => u.AppUserId == userId);
if (countOfRatingsThatAreUser == 1)
{
return 0;