Various improvements to game management interface

This commit is contained in:
grimsi
2022-08-05 18:34:24 +02:00
parent 22c8e99f38
commit 98197fc4a6
23 changed files with 446 additions and 170 deletions
@@ -54,6 +54,10 @@ export class GamesService implements GamesApi {
return this.http.get<Map<string, string>>(`${this.apiPath}/game-mappings`);
}
removeGameFromCache(slug: string): void {
this.cache.delete(slug);
}
private cacheGames(gameList: DetectedGameDto[]): void {
this.cache.clear();
gameList.forEach(game => this.cache.set(game.slug, game));