Skip to content

Commit

Permalink
Ensure that the slug is always within the 50 characters it needs to be.
Browse files Browse the repository at this point in the history
  • Loading branch information
Corey Oordt committed Aug 18, 2011
1 parent 4107cdd commit 5a74525
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion categories/management/commands/import_categories.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def make_category(self, string, parent=None, order=1):
"""
return Category.objects.create(
name=string.strip(),
slug=slugify(string.strip()),
slug=slugify(string.strip())[:49],
parent=parent,
order=order
)
Expand Down

0 comments on commit 5a74525

Please sign in to comment.