Update django_orm.py

Deal with changes for django 1.7