~sircmpwn/todo.sr.ht

ba12050c5f3ec83df59d435681a0cbc1422127b2 — Drew DeVault a month ago 2c8901c 0.62.3
API: fix error with editing comments

This was fixed earlier in the web blueprints but the API was never
updated accordingly.
1 files changed, 3 insertions(+), 1 deletions(-)

M todosrht/blueprints/api/tickets.py
M todosrht/blueprints/api/tickets.py => todosrht/blueprints/api/tickets.py +3 -1
@@ 318,7 318,9 @@ def tracker_comment_by_id_PUT(username, tracker_name, ticket_id, comment_id):
    valid = Validation(request)
    text = valid.require("text")

    event = Event.query.filter(Event.comment_id == comment.id).one_or_none()
    event = (Event.query
            .filter(Event.comment_id == comment.id)
            .order_by(Event.id.desc())).first()
    assert event is not None

    new_comment = TicketComment()