Skip to content

Commit

Permalink
Suppression d'une relation erronée
Browse files Browse the repository at this point in the history
Django 1.8 vérifie ces relations et donc lancerait une erreur.
Cf https://docs.djangoproject.com/en/1.8/releases/1.8/#select-related-now-checks-given-fields
  • Loading branch information
SpaceFox authored and artragis committed Nov 11, 2015
1 parent 62ca42c commit 5af9f94
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion zds/mp/managers.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class PrivateTopicManager(models.Manager):
def get_private_topics_of_user(self, user_id):
return super(PrivateTopicManager, self).get_queryset() \
.filter(Q(participants__in=[user_id]) | Q(author=user_id)) \
.select_related("author", "participants") \
.select_related("author") \
.distinct().order_by('-last_message__pubdate').all()

def get_private_topics_selected(self, user_id, pks):
Expand Down

0 comments on commit 5af9f94

Please sign in to comment.