revert: restore page-by-page download method (old method works better)

This commit is contained in:
Julien Froidefond
2026-01-04 11:39:55 +01:00
parent 1ffe99285d
commit ad11bce308
5 changed files with 65 additions and 161 deletions

View File

@@ -115,27 +115,6 @@ export class BookService extends BaseApiService {
}
}
static async getFile(bookId: string): Promise<Response> {
try {
const config = await this.getKomgaConfig();
const url = this.buildUrl(config, `books/${bookId}/file`);
const headers = this.getAuthHeaders(config);
const response = await fetch(url, {
method: "GET",
headers,
});
if (!response.ok) {
throw new AppError(ERROR_CODES.BOOK.NOT_FOUND);
}
return response;
} catch (error) {
throw new AppError(ERROR_CODES.BOOK.NOT_FOUND, {}, error);
}
}
static async getCover(bookId: string): Promise<Response> {
try {
// Récupérer les préférences de l'utilisateur