diff options
Diffstat (limited to 'accounts/models.py')
-rw-r--r-- | accounts/models.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/accounts/models.py b/accounts/models.py index aa0e4d0..45648a4 100644 --- a/accounts/models.py +++ b/accounts/models.py @@ -51,7 +51,8 @@ class Account(UserMixin): self._set_attribute('mail', new_mail) def __getattr__(self, name): - if name in self.attributes: + # https://stackoverflow.com/a/47300262 + if name[:2] != "__" and name in self.attributes: return self.attributes[name] raise AttributeError("'%s' object has no attribute '%s'" % |