This fixes a bug that was introduced in 28ff6fb1 [1] for the browsable API, specifically with how it handled default values for boolean fields. Previously, it had a global default for boolean fields set to `False`, which was different than the standard None that was used elsewhere. Because this only needed to be done for the browsable API, a fix was put into place that only set the default to `False` when form data was passed into the serializer. This had the unintended side effect of overriding any default set on the boolean field. This fixes #1101 [2] by only overriding the default if the default is `None`, which is the default for all fields. [1]: https://github.com/tomchristie/django-rest-framework/commit/28ff6fb1ec02b7a04c4a0db54885f3735b6dd43f [2]: https://github.com/tomchristie/django-rest-framework/issues/1101
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
extras | Loading commit data... | |
__init__.py | Loading commit data... | |
description.py | Loading commit data... | |
models.py | Loading commit data... | |
test_authentication.py | Loading commit data... | |
test_breadcrumbs.py | Loading commit data... | |
test_decorators.py | Loading commit data... | |
test_description.py | Loading commit data... | |
test_fields.py | Loading commit data... | |
test_files.py | Loading commit data... | |
test_filters.py | Loading commit data... | |
test_genericrelations.py | Loading commit data... | |
test_generics.py | Loading commit data... | |
test_htmlrenderer.py | Loading commit data... | |
test_hyperlinkedserializers.py | Loading commit data... | |
test_multitable_inheritance.py | Loading commit data... | |
test_negotiation.py | Loading commit data... | |
test_pagination.py | Loading commit data... | |
test_parsers.py | Loading commit data... | |
test_permissions.py | Loading commit data... | |
test_relations.py | Loading commit data... | |
test_relations_hyperlink.py | Loading commit data... | |
test_relations_nested.py | Loading commit data... | |
test_relations_pk.py | Loading commit data... | |
test_relations_slug.py | Loading commit data... | |
test_renderers.py | Loading commit data... | |
test_request.py | Loading commit data... | |
test_response.py | Loading commit data... | |
test_reverse.py | Loading commit data... | |
test_routers.py | Loading commit data... | |
test_serializer.py | Loading commit data... | |
test_serializer_bulk_update.py | Loading commit data... | |
test_serializer_empty.py | Loading commit data... | |
test_serializer_nested.py | Loading commit data... | |
test_settings.py | Loading commit data... | |
test_status.py | Loading commit data... | |
test_testing.py | Loading commit data... | |
test_throttling.py | Loading commit data... | |
test_urlpatterns.py | Loading commit data... | |
test_validation.py | Loading commit data... | |
test_views.py | Loading commit data... | |
tests.py | Loading commit data... |