1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #20784 -- Added inverse_match parameter to RegexValidator.

This commit is contained in:
Si Feng
2013-07-21 17:27:56 -07:00
committed by Tim Graham
parent 0d98422b13
commit b102c27ff4
4 changed files with 29 additions and 6 deletions

View File

@@ -697,6 +697,12 @@ Tests
Validators
^^^^^^^^^^
* :class:`~django.core.validators.RegexValidator` now accepts an optional
Boolean :attr:`~django.core.validators.RegexValidator.inverse_match` argument
which determines if the :exc:`~django.core.exceptions.ValidationError` should
be raised when the regular expression pattern matches (``True``) or does not
match (``False``, by default) the provided ``value``.
* :class:`~django.core.validators.URLValidator` now accepts an optional
``schemes`` argument which allows customization of the accepted URI schemes
(instead of the defaults ``http(s)`` and ``ftp(s)``).