Ensure that the slug is always within the 50 characters it needs to be.

This commit is contained in:
Corey Oordt 2011-08-18 10:31:52 -04:00
parent 4107cdd125
commit 5a74525446

View file

@ -29,7 +29,7 @@ class Command(BaseCommand):
"""
return Category.objects.create(
name=string.strip(),
slug=slugify(string.strip()),
slug=slugify(string.strip())[:49],
parent=parent,
order=order
)