Indeed, my last iteration of the patch before @coder9042 took handled `AttributeError` like `None`, see https://code.djangoproject.com/attachment/ticket/10811/10811-2.patch.