Switching uuid4()[1:4] -> uuid4().hex[:4]
.hex is what we need to access to get at the ascii (hex) version anyway. Also, not sure why the previous version grabbed starting at the index of 1... just grab the first characters instead.
This commit is contained in:
parent
985871095e
commit
266b42b3dc
@ -111,7 +111,7 @@ class MediaEntryMixin(object):
|
||||
# let's whack junk on there till it's unique.
|
||||
self.slug += '-'
|
||||
while check_media_slug_used(self.uploader, self.slug, self.id):
|
||||
self.slug += uuid4()[1:4]
|
||||
self.slug += uuid4().hex[:4]
|
||||
|
||||
@property
|
||||
def description_html(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user