1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Fixes user delete when they have a bookmark (#14867)

* fixes user delete when they have a bookmark #14851

* Include migration for user field

---------

Co-authored-by: Jeremy Stretch <jstretch@netboxlabs.com>
This commit is contained in:
Abhimanyu Saharan
2024-01-20 01:53:20 +05:30
committed by GitHub
parent 749fc31bc4
commit a87d76ad17
2 changed files with 22 additions and 1 deletions

View File

@@ -771,7 +771,7 @@ class Bookmark(models.Model):
)
user = models.ForeignKey(
to=settings.AUTH_USER_MODEL,
on_delete=models.PROTECT
on_delete=models.CASCADE
)
objects = RestrictedQuerySet.as_manager()