From edf3b14473b4166659365e9c9b80b4344bfe5978 Mon Sep 17 00:00:00 2001 From: Sam Ireland Date: Mon, 12 Feb 2024 10:39:03 +0000 Subject: [PATCH] BigIntegerField -> PositiveBigIntegerField (resolves #3) --- django_random_id_model.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django_random_id_model.py b/django_random_id_model.py index df63807..1a6942a 100644 --- a/django_random_id_model.py +++ b/django_random_id_model.py @@ -18,7 +18,7 @@ class RandomIDModel(models.Model): class Meta: abstract = True - id = models.BigIntegerField(primary_key=True) + id = models.PositiveBigIntegerField(primary_key=True) def save(self, *args, **kwargs): """If the user hasn't provided an ID, generate one at random and check