Change for Django 1.5.4, no more redirect_to

svn: r23376
This commit is contained in:
Doug Blank 2013-10-23 17:45:42 +00:00
parent b91927e37c
commit fb704558e2

View File

@ -62,7 +62,11 @@ urlpatterns += patterns('',
# The rest will match views: # The rest will match views:
urlpatterns += patterns('', urlpatterns += patterns('',
(r'^$', main_page), (r'^$', main_page),
(r'^favicon\.ico$', 'django.views.generic.simple.redirect_to', ## Prior to django 1.5, use this:
##(r'^favicon\.ico$', 'django.views.generic.simple.redirect_to',
##{'url': '/styles/images/favicon.ico'}),
# Django 1.5.4:
(r'^favicon\.ico$', 'django.shortcuts.redirect',
{'url': '/styles/images/favicon.ico'}), {'url': '/styles/images/favicon.ico'}),
(r'^user/$', user_page), (r'^user/$', user_page),
(r'^json/$', process_json_request), (r'^json/$', process_json_request),