Fix for python 26 and django <1.5
cleanup [ci skip]