Fixed a failure against Django < 1.6