Add ratism to chatbox
This commit is contained in:
parent
ca89510799
commit
acec52f71b
2 changed files with 15 additions and 10 deletions
|
@ -14,10 +14,11 @@ import json
|
|||
def format_messages(messages):
|
||||
msg_list = [{
|
||||
'time': msg.time,
|
||||
'author': str(msg.author),
|
||||
'author': msg.author,
|
||||
'body': msg.body,
|
||||
'image': gravatar(msg.author, 32),
|
||||
'id': msg.id
|
||||
'id': msg.id,
|
||||
'css_class': msg.author.css_class,
|
||||
} for msg in messages]
|
||||
return json.dumps(msg_list, default=str)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue