feat: clean cache on home
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { BaseApiService } from "./base-api.service";
|
||||
import { KomgaBook, KomgaSeries } from "@/types/komga";
|
||||
import { LibraryResponse } from "@/types/library";
|
||||
import { serverCacheService } from "./server-cache.service";
|
||||
|
||||
interface HomeData {
|
||||
ongoing: KomgaSeries[];
|
||||
@@ -63,4 +64,10 @@ export class HomeService extends BaseApiService {
|
||||
return this.handleError(error, "Impossible de récupérer les données de la page d'accueil");
|
||||
}
|
||||
}
|
||||
|
||||
static async clearHomeCache() {
|
||||
serverCacheService.delete("home-ongoing");
|
||||
serverCacheService.delete("home-recently-read");
|
||||
serverCacheService.delete("home-on-deck");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user