Permalink
Browse files

Changes needed for Django 1.6+ (conf.url api change)

  • Loading branch information...
1 parent 2f7ab47 commit 9814bbf9d1977c21bbc1793bbdbd53c414f1b0ba @vierja vierja committed Nov 19, 2014
Showing with 4 additions and 1 deletion.
  1. +4 −1 extendedmodelresource/extendedmodelresource.py
@@ -1,7 +1,10 @@
from django.http import HttpResponse
from django.core.exceptions import ObjectDoesNotExist, MultipleObjectsReturned
from django.core.urlresolvers import get_script_prefix, resolve, Resolver404
-from django.conf.urls.defaults import patterns, url, include
+try:
+ from django.conf.urls import patterns, url, include
+except ImportError:
+ from django.conf.urls.defaults import patterns, url, include
from tastypie import fields, http
from tastypie.exceptions import NotFound, ImmediateHttpResponse

0 comments on commit 9814bbf

Please sign in to comment.