master
Aevann1 2021-07-30 10:28:18 +02:00
parent 81dc29d99a
commit 35cb331f5a
1 changed files with 6 additions and 3 deletions

View File

@ -40,11 +40,14 @@ def log(v):
"api":lambda:jsonify({"data":[x.json for x in actions]})
}
@app.get("/log/<aid>")
@app.get("/log/<id>")
@auth_desired
def log_item(aid, v):
def log_item(id, v):
action=g.db.query(ModAction).filter_by(id=aid).first()
try: id = int(id)
except: id = int(id, 36)
action=g.db.query(ModAction).filter_by(id=id).first()
if not action:
abort(404)