add index page to server post()

This commit is contained in:
iou1name 2019-06-02 18:26:07 -04:00
parent 68e25bcdcc
commit 508b2781f1

View File

@ -52,8 +52,11 @@ def post():
db.save('modpack.db') db.save('modpack.db')
app.config.get('db_lock').release() app.config.get('db_lock').release()
summary = request.files.get(config_server.modpack_name + '.html')
summary.save(config_server.modpack_name + '.html')
for fname, file in request.files.items(): for fname, file in request.files.items():
if fname == 'modpack.db': if not fname.endswith('.jar'):
continue continue
file.save(os.path.join(config_server.mods_dir, fname)) file.save(os.path.join(config_server.mods_dir, fname))