Skip to content
Snippets Groups Projects

Make virtual foreign key optional

Merged Jonathan Weth requested to merge fix/make-virtual-foreign-key-optional into master
1 file
+ 1
1
Compare changes
  • Side-by-side
  • Inline
+ 1
1
@@ -232,7 +232,7 @@ class ExtensibleModel(models.Model, metaclass=_ExtensibleModelBase):
related_name = cls.Meta.default_related_name
# Add field to hold key to foreign model
id_field = to_field_type()
id_field = to_field_type(blank=True, null=True)
cls.field(**{id_field_name: id_field})
@property
Loading