Adding compatibility with current Django trunk.