mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-07-27 16:40:03 +03:00
url()'s were replaced by path, and imports were sorted in urlpatterns.py
This commit is contained in:
parent
71ab8974b0
commit
bbed943323
|
@ -1,4 +1,4 @@
|
||||||
from django.conf.urls import include, url
|
from django.urls import include, path
|
||||||
|
|
||||||
from rest_framework.renderers import (
|
from rest_framework.renderers import (
|
||||||
CoreJSONRenderer, DocumentationRenderer, SchemaJSRenderer
|
CoreJSONRenderer, DocumentationRenderer, SchemaJSRenderer
|
||||||
|
@ -82,7 +82,7 @@ def include_docs_urls(
|
||||||
permission_classes=permission_classes,
|
permission_classes=permission_classes,
|
||||||
)
|
)
|
||||||
urls = [
|
urls = [
|
||||||
url(r'^$', docs_view, name='docs-index'),
|
path('', docs_view, name='docs-index'),
|
||||||
url(r'^schema.js$', schema_js_view, name='schema-js')
|
path('schema.js', schema_js_view, name='schema-js')
|
||||||
]
|
]
|
||||||
return include((urls, 'api-docs'), namespace='api-docs')
|
return include((urls, 'api-docs'), namespace='api-docs')
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
from django.conf.urls import include
|
from django.urls import URLResolver, include, path, re_path, register_converter
|
||||||
from django.urls import URLResolver, path, re_path, register_converter
|
|
||||||
from django.urls.resolvers import RoutePattern
|
from django.urls.resolvers import RoutePattern
|
||||||
|
|
||||||
from rest_framework.settings import api_settings
|
from rest_framework.settings import api_settings
|
||||||
|
|
Loading…
Reference in New Issue
Block a user