"""
above function is not my code, but i don't remember exactly where it comes from
you can find many snippets with such solutions searching for 'unique slug' and so
"""


class ReviewForm(forms.ModelForm):

    def save(self, user, commit=True):
        self.instance.slug = slugify_unique(self.cleaned_data['title'],
            self.Meta.model)
Django slugified urls - how to handle collisions?