File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -77,6 +77,15 @@ a more permissive regular expression for it:
77
77
78
78
That's it! Now, the ``{token} `` parameter can contain the ``/ `` character.
79
79
80
+ .. note ::
81
+
82
+ If the route includes the special ``{_format} `` placeholder, you shouldn't
83
+ use the ``.+ `` requirement for the parameters that allow slashes. For example,
84
+ if the pattern is ``/share/{token}.{_format} `` and ``{token} `` allows any
85
+ character, the ``/share/foo/bar.json `` URL will consider ``foo/bar.json ``
86
+ as the token and the format will be empty. This can be solved replacing the
87
+ ``.+ `` requirement by ``[^.]+ `` to allow any character except dots.
88
+
80
89
.. note ::
81
90
82
91
If the route defines several placeholders and you apply this permissive
You can’t perform that action at this time.
0 commit comments