From 2ca024941a45830c1d8ebbbaf3546d293254a792 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=81=8D=E5=85=AE=E6=83=9A=E5=85=AE?= <101191390+HIllya51@users.noreply.github.com> Date: Thu, 27 Jun 2024 20:44:10 +0800 Subject: [PATCH] fix --- LunaTranslator/LunaTranslator/metadata/vndb.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/LunaTranslator/LunaTranslator/metadata/vndb.py b/LunaTranslator/LunaTranslator/metadata/vndb.py index 7bfd6b0f..795c448c 100644 --- a/LunaTranslator/LunaTranslator/metadata/vndb.py +++ b/LunaTranslator/LunaTranslator/metadata/vndb.py @@ -287,7 +287,7 @@ class vndbsettings(QDialog): self._ref.proxy, "GET", "authinfo", headers=self.headers )["id"] - def querylist(self, needtitle): + def querylist(self): userid = self.userid pagei = 1 @@ -295,9 +295,7 @@ class vndbsettings(QDialog): while True: json_data = { "user": userid, - "fields": ( - "id, vn.title,vn.titles.title,vn.titles.main" if needtitle else "id" - ), + "fields": ("id, vn.title,vn.titles.title,vn.titles.main"), "sort": "vote", "results": 100, "page": pagei, @@ -323,7 +321,7 @@ class vndbsettings(QDialog): collect[vid] = gameuid for item in collectresults: - title = item["name"] + title = gettitlefromjs(item["vn"]) vid = int(item["id"][1:]) if vid in thislistvids: continue @@ -338,7 +336,7 @@ class vndbsettings(QDialog): def getalistname_upload(self, uid): reflist = getreflist(uid) - vids = [int(item["id"][1:]) for item in self.querylist(False)] + vids = [int(item["id"][1:]) for item in self.querylist()] for gameuid in reflist: vid = savehook_new_data[gameuid][self._ref.idname]