Skip to content

Commit

Permalink
Revert "Fixed #20956 -- Removed useless check in django.db.utils"
Browse files Browse the repository at this point in the history
This reverts commit ce0e86c.

The check is necessary if 'ENGINE' is an empty string.
Thanks apollo13 for pointing this out.
  • Loading branch information
timgraham committed Aug 22, 2013
1 parent 2e926b0 commit 768bbf3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion django/db/utils.py
Expand Up @@ -173,7 +173,7 @@ def ensure_defaults(self, alias):
conn.setdefault('AUTOCOMMIT', False) conn.setdefault('AUTOCOMMIT', False)
conn.setdefault('AUTOCOMMIT', True) conn.setdefault('AUTOCOMMIT', True)
conn.setdefault('ENGINE', 'django.db.backends.dummy') conn.setdefault('ENGINE', 'django.db.backends.dummy')
if conn['ENGINE'] == 'django.db.backends.': if conn['ENGINE'] == 'django.db.backends.' or not conn['ENGINE']:
conn['ENGINE'] = 'django.db.backends.dummy' conn['ENGINE'] = 'django.db.backends.dummy'
conn.setdefault('CONN_MAX_AGE', 0) conn.setdefault('CONN_MAX_AGE', 0)
conn.setdefault('OPTIONS', {}) conn.setdefault('OPTIONS', {})
Expand Down

0 comments on commit 768bbf3

Please sign in to comment.