From 4e2612aaaf81041de9569e59d20163f8f810071b Mon Sep 17 00:00:00 2001 From: Matthieu Rigal Date: Tue, 22 Sep 2020 16:52:43 +0200 Subject: [PATCH] Fix example urls to work with recent Django --- example/urls.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/example/urls.py b/example/urls.py index 41bfb54..224e992 100644 --- a/example/urls.py +++ b/example/urls.py @@ -1,11 +1,11 @@ from django.conf import settings -from django.conf.urls import include, patterns, static, url +from django.conf.urls import static from django.contrib import admin +from django.urls import path admin.autodiscover() -urlpatterns = patterns( - "", - url(r"^admin/", include(admin.site.urls)), -) +urlpatterns = [ + path('admin/', admin.site.urls), +] urlpatterns += static.static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)