              unique_together = (('first_name', 'last_name'),)
  
      class Book(models.Model):
          name = models.CharField(max_length=100)
          author = models.ForeignKey(Person)
  
  Ordinarily, serialized data for ``Book`` would use an integer to refer to
  the author. For example, in JSON, a Book might be serialized as::
  
      ...
 
</s> remove         author = models.ForeignKey(Person)
 </s> add         author = models.ForeignKey(Person, on_delete=models.CASCADE) </s> remove         author = models.ForeignKey(Author)
 </s> add         author = models.ForeignKey(Author, on_delete=models.CASCADE) </s> remove model was altered to ``blog = ForeignKey(Blog, related_name='entries')``, the
above example code would look like this::
 </s> add model was altered to ``blog = ForeignKey(Blog, on_delete=models.CASCADE,
related_name='entries')``, the above example code would look like this:: </s> remove         from_friend = models.ForeignKey(Friend, related_name='from_friends')
        to_friend = models.ForeignKey(Friend, related_name='friends')
 </s> add         from_friend = models.ForeignKey(
            Friend,
            on_delete=models.CASCADE,
            related_name='from_friends',
        )
        to_friend = models.ForeignKey(
            Friend,
            on_delete=models.CASCADE,
            related_name='friends',
        ) </s> remove     x1 = models.ForeignKey(X, related_name='y1')
 </s> add     x1 = models.ForeignKey(X, models.CASCADE, related_name='y1')
        author = models.ForeignKey(Person, on_delete=models.CASCADE)
              unique_together = (('first_name', 'last_name'),)
  
      class Book(models.Model):
          name = models.CharField(max_length=100)
        author = models.ForeignKey(Person, on_delete=models.CASCADE)
  
  Ordinarily, serialized data for ``Book`` would use an integer to refer to
  the author. For example, in JSON, a Book might be serialized as::
  
      ...
keep keep keep keep replace keep keep keep keep keep
 Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField 
docs/topics/serialization.txt