handle deprecation warnings when using django 1.5