mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-26 19:43:59 +03:00
Use app for Django 1.2
This commit is contained in:
parent
0f49f9b2b5
commit
cbac9244ac
|
@ -1,7 +1,10 @@
|
||||||
from django.conf.urls.defaults import patterns, include, url
|
from django.conf.urls.defaults import patterns, include
|
||||||
from django.conf import settings
|
|
||||||
from sandbox.views import Sandbox
|
from sandbox.views import Sandbox
|
||||||
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
|
try:
|
||||||
|
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
|
||||||
|
except ImportError: # Django <= 1.2
|
||||||
|
from staticfiles.urls import staticfiles_urlpatterns
|
||||||
|
|
||||||
|
|
||||||
urlpatterns = patterns('',
|
urlpatterns = patterns('',
|
||||||
(r'^$', Sandbox.as_view()),
|
(r'^$', Sandbox.as_view()),
|
||||||
|
|
Loading…
Reference in New Issue
Block a user