update for django 1.7 and new best practices