1
0
mirror of https://github.com/immich-app/immich.git synced 2025-07-05 06:00:24 +02:00

refactor: library type (#9525)

This commit is contained in:
Jason Rasmussen
2024-05-20 18:09:10 -04:00
committed by GitHub
parent 4353153fe6
commit 84d824d6a7
66 changed files with 183 additions and 984 deletions

View File

@ -104,10 +104,7 @@ class LibraryApi {
}
/// Performs an HTTP 'GET /library' operation and returns the [Response].
/// Parameters:
///
/// * [LibraryType] type:
Future<Response> getAllLibrariesWithHttpInfo({ LibraryType? type, }) async {
Future<Response> getAllLibrariesWithHttpInfo() async {
// ignore: prefer_const_declarations
final path = r'/library';
@ -118,10 +115,6 @@ class LibraryApi {
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (type != null) {
queryParams.addAll(_queryParams('', 'type', type));
}
const contentTypes = <String>[];
@ -136,11 +129,8 @@ class LibraryApi {
);
}
/// Parameters:
///
/// * [LibraryType] type:
Future<List<LibraryResponseDto>?> getAllLibraries({ LibraryType? type, }) async {
final response = await getAllLibrariesWithHttpInfo( type: type, );
Future<List<LibraryResponseDto>?> getAllLibraries() async {
final response = await getAllLibrariesWithHttpInfo();
if (response.statusCode >= HttpStatus.badRequest) {
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
}