made it compatible with django1.6 (I think)

According to [this](http://stackoverflow.com/a/20246225/3210025) and [#ticket 13696](https://github.com/kmtracey/django/commit/9e5519f50536288db2ae0c6fa4b95193788dfb7a)