Skip to content
This repository has been archived by the owner on Apr 25, 2022. It is now read-only.

Commit

Permalink
Remove app stats when apps are removed
Browse files Browse the repository at this point in the history
  • Loading branch information
razzeee committed Nov 29, 2021
1 parent 686d2dd commit 6d9e37e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app/apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,12 @@ def load_appstream():
p.sadd(f"categories:{category}", redis_key)

for appid in current_apps - set(apps):
p.delete(f"apps:{appid}", f"fts:{appid}", f"summary:{appid}")
p.delete(
f"apps:{appid}",
f"fts:{appid}",
f"summary:{appid}",
f"app_stats:{appid}",
)
db.redis_search.delete_document(f"fts:{appid}")

new_apps = set(apps) - current_apps
Expand Down

0 comments on commit 6d9e37e

Please sign in to comment.