@@ -0,0 +1,947 @@
+from django.conf import settings%0Afrom django.core.exceptions import ImproperlyConfigured%0Afrom django.utils.importlib import import_module%0A%0Adef get_backend():%0A    %22%22%22%0A    Return an instance of the registration backend for use on this%0A    site, as determined by the %60%60REGISTRATION_BACKEND%60%60 setting. Raise%0A    %60%60django.core.exceptions.ImproperlyConfigured%60%60 if the specified%0A    backend cannot be located.%0A    %0A    %22%22%22%0A    i = settings.REGISTRATION_BACKEND.rfind('.')%0A    module, attr = settings.REGISTRATION_BACKEND%5B:i%5D, settings.REGISTRATION_BACKEND%5Bi+1:%5D%0A    try:%0A        mod = import_module(module)%0A    except ImportError, e:%0A        raise ImproperlyConfigured('Error loading registration backend %25s: %22%25s%22' %25 (module, e))%0A    try:%0A        backend_class = getattr(mod, attr)%0A    except AttributeError:%0A        raise ImproperlyConfigured('Module %22%25s%22 does not define a registration backend named %22%25s%22' %25 (module, attr))%0A    return backend_class()%0A

Add utility function for retrieving the active registration backend.