Ticket #5563: booleanfield-to-python-can-be-none.patch

File booleanfield-to-python-can-be-none.patch, 533 bytes (added by shaunc <shaun@…>, 17 years ago)

(patch to fix django.db.models.fields.init.py

  • __init__.py

     
    405405        if value in (True, False): return value
    406406        if value in ('t', 'True', '1'): return True
    407407        if value in ('f', 'False', '0'): return False
     408        if value is None and self.null == True: return None
    408409        raise validators.ValidationError, gettext("This value must be either True or False.")
    409410
    410411    def get_manipulator_field_objs(self):
Back to Top