Skip to content

Conversation

@juliawuu
Copy link

No description provided.

'name': '@%s' % (commenter.username),
'avatar': gravatar_for_user(commenter),
'type': 'contact'})
if len(data) > 10:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't it be >= 10? (if we want a maximum of 10 results).

messages = ChatMessage.objects.filter(url=url).order_by('-date').select_related()

id_list = []
for suggested_user in data:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not just create id_list above and add an append inside the for loop where items get added to data?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants