1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2024-12-26 09:37:25 +00:00

Fixed language filter in history stats.

This commit is contained in:
morpheus65535 2021-06-10 06:48:45 -04:00
parent c21e501ebe
commit 29fffd4e81

View file

@ -353,8 +353,12 @@ class Languages(Resource):
def get(self): def get(self):
history = request.args.get('history') history = request.args.get('history')
if history and history not in False_Keys: if history and history not in False_Keys:
languages = list(TableHistory.select(TableHistory.language).dicts()) languages = list(TableHistory.select(TableHistory.language)
languages += list(TableHistoryMovie.select(TableHistoryMovie.language).dicts()) .where(TableHistory.language != None)
.dicts())
languages += list(TableHistoryMovie.select(TableHistoryMovie.language)
.where(TableHistoryMovie.language != None)
.dicts())
languages_set = set() languages_set = set()
for l in languages: for l in languages:
if l not in None_Keys and l['language'] not in None_Keys: if l not in None_Keys and l['language'] not in None_Keys: