fix
This commit is contained in:
parent
8d68450710
commit
942efb8036
2
api.py
2
api.py
@ -18,7 +18,7 @@ def main():
|
||||
@app.route('/dialog')
|
||||
def dialog():
|
||||
html = "<html><head></head><body>"
|
||||
for message in mongo.messages_collection.find({"dialog_id": ObjectId(request.args.get('dialog_id'))}).sort([('sent_at', 1)]):
|
||||
for message in mongo.messages_collection.find({"dialog_id": ObjectId(request.args.get('id'))}).sort([('sent_at', 1)]):
|
||||
html += f'{message["sender"]}: {message["text"]}<br>'
|
||||
html += "</body></html>"
|
||||
return html
|
||||
|
Loading…
Reference in New Issue
Block a user