Skip to content

Commit 4f59c7f

Browse files
committed
Expose to user mongoengine.base.NON_FIELD_ERRORS
This variable is used to set the field containing the errors raised in a clean function. Given those function are user-defined, users should be able to get the name of the field to easily retreive their custom errors.
1 parent 21d1faa commit 4f59c7f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mongoengine/base/document.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from mongoengine.errors import (FieldDoesNotExist, InvalidDocumentError,
2020
LookUpError, OperationError, ValidationError)
2121

22-
__all__ = ('BaseDocument',)
22+
__all__ = ('BaseDocument', 'NON_FIELD_ERRORS')
2323

2424
NON_FIELD_ERRORS = '__all__'
2525

0 commit comments

Comments
 (0)