Use more straightforward approach to get organizations from user

This commit is contained in:
Kumi 2019-02-01 12:16:28 +00:00
parent d1935e4884
commit a1be826eeb

View file

@ -5,4 +5,4 @@ register = template.Library()
@register.simple_tag
def orgaString(user):
return ", ".join(str(orga) for orga in Organization.objects.filter(users=user))
return ", ".join(str(orga) for orga in user.organization_set.all())