mirror of
				https://github.com/Kareadita/Kavita.git
				synced 2025-10-31 02:27:04 -04:00 
			
		
		
		
	* Added a new endpoint to get all Series with Progress info. * Fixed up some potential NPEs during scan * Commented out filter code, not ready for it. * Fixed up a parsing case for european comics * Refactored FilterDto to allow for specifying multiple formats to return. * Refactored FilterDto to allow for specifying multiple formats to return. * Refactored the UI to show OPDS as 3rd Party Clients since Tachiyomi now uses OPDS url scheme for authentication.
		
			
				
	
	
		
			23 lines
		
	
	
		
			550 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			550 B
		
	
	
	
		
			C#
		
	
	
	
	
	
| using System;
 | |
| using System.Collections.Generic;
 | |
| using API.DTOs.Filtering;
 | |
| using API.Entities.Enums;
 | |
| 
 | |
| namespace API.Extensions
 | |
| {
 | |
|     public static class FilterDtoExtensions
 | |
|     {
 | |
|         private static readonly IList<MangaFormat> AllFormats = Enum.GetValues<MangaFormat>();
 | |
| 
 | |
|         public static IList<MangaFormat> GetSqlFilter(this FilterDto filter)
 | |
|         {
 | |
|             if (filter.Formats == null || filter.Formats.Count == 0)
 | |
|             {
 | |
|                 return AllFormats;
 | |
|             }
 | |
| 
 | |
|             return filter.Formats;
 | |
|         }
 | |
|     }
 | |
| }
 |