mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-08-07 22:04:48 +03:00
Merge a74b3a711e
into 9b56dda918
This commit is contained in:
commit
3d981863cb
|
@ -24,7 +24,7 @@ def apply_suffix_patterns(urlpatterns, suffix_pattern, suffix_required):
|
|||
else:
|
||||
# Regular URL pattern
|
||||
regex = urlpattern.regex.pattern.rstrip('$').rstrip('/') + suffix_pattern
|
||||
view = urlpattern._callback or urlpattern._callback_str
|
||||
view = getattr(urlpattern, 'callback', None) or urlpattern._callback or urlpattern._callback_str
|
||||
kwargs = urlpattern.default_args
|
||||
name = urlpattern.name
|
||||
# Add in both the existing and the new urlpattern
|
||||
|
|
Loading…
Reference in New Issue
Block a user