X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/bdf5017081b6f2017bed812c8276a9b693d8c564..07a8fb3687c7e82ab8d4c172c90269f32b818217:/apps/api/urls.py?ds=inline diff --git a/apps/api/urls.py b/apps/api/urls.py index f9f9c2279..e24c3c523 100644 --- a/apps/api/urls.py +++ b/apps/api/urls.py @@ -1,6 +1,7 @@ # -*- coding: utf-8 -*- from django.conf.urls.defaults import * from django.views.decorators.csrf import csrf_exempt +from django.views.generic import TemplateView from piston.authentication import OAuthAuthentication, oauth_access_token from piston.resource import Resource @@ -32,8 +33,7 @@ urlpatterns = patterns( url(r'^oauth/access_token/$', csrf_exempt(oauth_access_token)), ) + patterns('', - url(r'^$', 'django.views.generic.simple.direct_to_template', - {'template': 'api/main.html'}, name='api'), + url(r'^$', TemplateView.as_view(template_name='api/main.html'), name='api'), # changes handlers