summaryrefslogtreecommitdiff
path: root/django
diff options
context:
space:
mode:
authorAdrian Holovaty <adrian@holovaty.com>2011-03-17 16:57:37 +0000
committerAdrian Holovaty <adrian@holovaty.com>2011-03-17 16:57:37 +0000
commit6091f0ead37b4339a781c731abee85ae00ab0e99 (patch)
tree6c8e2c2443bb714f8ac21476ece7e7a53db2af82 /django
parenta0878b5f95b5fc5bac02d818e864cab507b73564 (diff)
downloaddjango-6091f0ead37b4339a781c731abee85ae00ab0e99.tar.gz
Fixed #15621 -- Fixed potentially confusing error message in db backend loading. Thanks, keegan_csmith
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15871 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django')
-rw-r--r--django/db/utils.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/django/db/utils.py b/django/db/utils.py
index e3f36bdd03..4f30b7ae2f 100644
--- a/django/db/utils.py
+++ b/django/db/utils.py
@@ -41,6 +41,8 @@ def load_backend(backend_name):
and not f.startswith('.')]
except EnvironmentError:
available_backends = []
+ if backend_name.startswith('django.db.backends.'):
+ backend_name = backend_name[19:] # See #15621.
if backend_name not in available_backends:
error_msg = ("%r isn't an available database backend. \n" +
"Try using django.db.backends.XXX, where XXX is one of:\n %s\n" +