8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-09-12 01:03:09 +00:00

Fix réponses multiples, ne crash pas

This commit is contained in:
Gabriel Detraz 2019-10-14 23:43:36 +02:00 committed by root
parent 5faf134690
commit d51f1e126d

View file

@ -768,7 +768,7 @@ class User(RevMixin, FieldPermissionModelMixin, AbstractBaseUser,
def autoregister_machine(self, mac_address, nas_type):
""" Fonction appellée par freeradius. Enregistre la mac pour
une machine inconnue sur le compte de l'user"""
allowed, _message = Machine.can_create(self, self.id)
allowed, _message, _rights = Machine.can_create(self, self.id)
if not allowed:
return False, _("Maximum number of registered machines reached.")
if not nas_type: