Skip to content

Commit

Permalink
Use 1.10 patterns style.
Browse files Browse the repository at this point in the history
  • Loading branch information
ionelmc committed Aug 20, 2016
1 parent 6a01e82 commit 2702a2d
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions tests/test_app/urls.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
try:
from django.conf.urls import patterns, handler404, handler500, include, url
from django.conf.urls import url
except ImportError:
from django.conf.urls.defaults import patterns, handler404, handler500, include, url

urlpatterns = patterns('test_app.views',
url('^get/(.*)', 'get'),
url('^set/(.*)/(.*)', 'set'),
url('^add/(.*)/(.*)', 'add'),
url('^clear', 'clear'),
)
from django.conf.urls.defaults import url

from . import views


urlpatterns = [
url('^get/(.*)', views.get),
url('^set/(.*)/(.*)', views.set),
url('^add/(.*)/(.*)', views.add),
url('^clear', views.clear),
]

0 comments on commit 2702a2d

Please sign in to comment.