fix incorrect usage of add_field_errors in schema.py
This commit is contained in:
parent
c8b67c5c50
commit
44fc8d4615
1 changed files with 2 additions and 2 deletions
|
@ -199,7 +199,7 @@ class DeleteOTPSchema(DataRequiredSchema):
|
|||
|
||||
def admin_realm_validation(self):
|
||||
if self.admin_realm.value != decouple.config("ADMIN_REALM"):
|
||||
self.add_field_errors(
|
||||
self.add_error(
|
||||
"Admin must be from {} realm".format(decouple.config("ADMIN_REALM"))
|
||||
)
|
||||
|
||||
|
@ -233,7 +233,7 @@ class ListAccountSchema(DataRequiredSchema):
|
|||
|
||||
def admin_realm_validation(self):
|
||||
if self.admin_realm.value != decouple.config("ADMIN_REALM"):
|
||||
self.add_field_errors(
|
||||
self.add_error(
|
||||
"Admin must be from {} realm".format(decouple.config("ADMIN_REALM"))
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue