forked from MarseyWorld/MarseyWorld
master
parent
95fe4dffb1
commit
c14c5f4826
|
@ -219,7 +219,7 @@ def api_comment(v):
|
||||||
try:
|
try:
|
||||||
marsey = loads(body.lower())
|
marsey = loads(body.lower())
|
||||||
name = marsey["name"]
|
name = marsey["name"]
|
||||||
if "author" in marsey: author_id = get_user(marsey["author"])
|
if "author" in marsey: author_id = get_user(marsey["author"]).id
|
||||||
elif "author_id" in marsey: author_id = marsey["author_id"]
|
elif "author_id" in marsey: author_id = marsey["author_id"]
|
||||||
else: abort(400)
|
else: abort(400)
|
||||||
if not g.db.query(Marsey.name).filter_by(name=name).first():
|
if not g.db.query(Marsey.name).filter_by(name=name).first():
|
||||||
|
|
Loading…
Reference in New Issue