Fix player.ips

Removed circular method call
reminder
Etzelia 2018-10-18 16:53:40 +02:00
parent cb460e10c2
commit 03d343e44b
1 changed files with 4 additions and 3 deletions

View File

@ -170,9 +170,10 @@ class Player(models.Model):
@property @property
def ips(self): def ips(self):
ips = [] ips = []
query = IP.api.filter(player=self) if not getattr(self.auth_user, 'is_active', False):
for q in query: query = IP.objects.filter(player=self)
ips.append(q.ip) for q in query:
ips.append(q.ip)
return " ".join(ips) return " ".join(ips)
def __str__(self): def __str__(self):