Basic changes required for work with more modern versions of django