Kaydet (Commit) 6091f0ea authored tarafından Adrian Holovaty's avatar Adrian Holovaty

Fixed #15621 -- Fixed potentially confusing error message in db backend loading.…

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
üst a0878b5f
......@@ -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" +
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment