Skip to content

Commit fbe5603

Browse files
committed
Fix error: deprecated in
1 parent 2692250 commit fbe5603

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

examples/cookbook/cookbook/urls.py

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
from django.conf.urls import url
1+
# from django.conf.urls import url # Deprecated in Django 3.0, see https://stackoverflow.com/a/70319607
22
from django.contrib import admin
3+
from django.urls import re_path
34

45
from graphene_django.views import GraphQLView
56

67
urlpatterns = [
7-
url(r"^admin/", admin.site.urls),
8-
url(r"^graphql$", GraphQLView.as_view(graphiql=True)),
8+
re_path(r"^admin/", admin.site.urls),
9+
re_path(r"^graphql$", GraphQLView.as_view(graphiql=True)),
910
]

0 commit comments

Comments
 (0)