1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2024-12-25 01:02:19 +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):
history = request.args.get('history')
if history and history not in False_Keys:
languages = list(TableHistory.select(TableHistory.language).dicts())
languages += list(TableHistoryMovie.select(TableHistoryMovie.language).dicts())
languages = list(TableHistory.select(TableHistory.language)
.where(TableHistory.language != None)
.dicts())
languages += list(TableHistoryMovie.select(TableHistoryMovie.language)
.where(TableHistoryMovie.language != None)
.dicts())
languages_set = set()
for l in languages:
if l not in None_Keys and l['language'] not in None_Keys: