mirror of
https://github.com/django/django.git
synced 2025-08-02 18:13:02 +00:00
[5.1.x] Updated validate_slug regular expression in form validation docs.
Outdated since014247ad19
. Backport of63dbe30d33
from main.
This commit is contained in:
parent
4c079918e8
commit
d71c588d83
1 changed files with 1 additions and 1 deletions
|
@ -254,7 +254,7 @@ Common cases such as validating against an email or a regular expression can be
|
|||
handled using existing validator classes available in Django. For example,
|
||||
``validators.validate_slug`` is an instance of
|
||||
a :class:`~django.core.validators.RegexValidator` constructed with the first
|
||||
argument being the pattern: ``^[-a-zA-Z0-9_]+$``. See the section on
|
||||
argument being the pattern: ``^[-a-zA-Z0-9_]+\Z``. See the section on
|
||||
:doc:`writing validators </ref/validators>` to see a list of what is already
|
||||
available and for an example of how to write a validator.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue