dcramer / django-sphinx

A transparent layer for full-text search using Sphinx and Django
http://groups.google.com/group/django-sphinx
BSD 3-Clause "New" or "Revised" License
357 stars 122 forks source link

Patch fixed utils.config._get_database_engine for django 1.2.x #14

Open Apkawa opened 14 years ago

Apkawa commented 14 years ago

Hi. I written path http://paste.pocoo.org/show/263575/

In django new config as DATABASES[key]['ENGINE']

lamby commented 13 years ago

This patch does not detect MySQL correctly - settings.DATABASES['default']['ENGINE'] is a dotted-notation string like "django.db.backends.mysql" so comparing with "mysql" is wrong.

Also, "default" should be replaced with DEFAULT_DB_ALIAS.

Also, you make an unrelated change to the end of the file.