Commits

Jesper Nøhr committed e5cfc77

no such thing as import_module in django <1.1

  • Participants
  • Parent commits d394b4e

Comments (0)

Files changed (1)

File piston/authentication.py

 from django.core.exceptions import ImproperlyConfigured
 from django.shortcuts import render_to_response
 from django.template import RequestContext
-from django.utils.importlib import import_module
 
 from piston import forms
 
     module, attr = path[:i], path[i+1:]
 
     try:
-        mod = import_module(module)
+        mod = __import__(module, {}, {}, attr)
     except ImportError, e:
         raise ImproperlyConfigured, 'Error importing OAuth data store %s: "%s"' % (module, e)