Update plugins_api.py

pull/109/head
midoks 4 years ago
parent 918ea7d527
commit 103da95717
  1. 19
      class/core/plugins_api.py

@ -729,18 +729,21 @@ class plugins_api:
json_file = path + '/info.json' json_file = path + '/info.json'
if os.path.exists(json_file): if os.path.exists(json_file):
try: try:
data = json.loads(mw.readFile(json_file)) content = mw.readFile(json_file)
tmp_data = self.makeList(data) if content:
for index in range(len(tmp_data)): data = json.loads(content)
if tmp_data[index]['versions'] == info[1] or info[1] in tmp_data[index]['versions']: tmp_data = self.makeList(data)
tmp_data[index]['display'] = True for index in range(len(tmp_data)):
plist.append(tmp_data[index]) if tmp_data[index]['versions'] == info[1] or info[1] in tmp_data[index]['versions']:
continue tmp_data[index]['display'] = True
plist.append(tmp_data[index])
continue
except Exception as e: except Exception as e:
# raise e
print('getIndexList:', e) print('getIndexList:', e)
# 使用gevent模式时,无法使用多进程 # 使用gevent模式时,无法使用多进程
# plist = self.checkStatusMProcess(plist) #plist = self.checkStatusMProcess(plist)
plist = self.checkStatusMThreads(plist) plist = self.checkStatusMThreads(plist)
return plist return plist

Loading…
Cancel
Save