[gen] Minor updates.
This commit is contained in:
parent
af7a775570
commit
f91972c21a
|
@ -687,7 +687,7 @@ class Field:
|
|||
# because it can be raised as the result of reindexing
|
||||
# the object in situations that are not foreseen by
|
||||
# method in self.default.
|
||||
return None
|
||||
return
|
||||
else:
|
||||
return self.default
|
||||
return value
|
||||
|
|
|
@ -1098,7 +1098,7 @@ class ToolMixin(BaseMixin):
|
|||
# Try to authenticate this user
|
||||
user = self.authenticate(login, password, request)
|
||||
emergency = self._emergency_user
|
||||
if emergency and user is emergency:
|
||||
if emergency and (user is emergency):
|
||||
# It is the emergency user.
|
||||
return emergency.__of__(self)
|
||||
elif user is None:
|
||||
|
|
Loading…
Reference in a new issue