Model uid validator: fix off-by-1 error with the uid.
256bit is actually 43 base64 chars, not 44.
This commit is contained in:
@@ -20,7 +20,7 @@ from django.core.validators import RegexValidator
|
||||
from django.utils.functional import cached_property
|
||||
|
||||
|
||||
UidValidator = RegexValidator(regex=r'[a-zA-Z0-9\-_=]{44}', message='Not a valid UID. Expected a 256bit base64url.')
|
||||
UidValidator = RegexValidator(regex=r'[a-zA-Z0-9\-_=]{43}', message='Not a valid UID. Expected a 256bit base64url.')
|
||||
|
||||
|
||||
class Collection(models.Model):
|
||||
|
||||
Reference in New Issue
Block a user