def save(self, *args, **kwargs):
        if self.slug == '':
            self.slug = slugify(self.title)
        
        try:
            super(Thread, self).save(*args, **kwargs)
        except IntegrityError:
            self.slug = '%s-%s' % (self.slug, generate_extra_id())
            self.save(*args, **kwargs)
dataset/ETHPy150Open kylef-archive/lithium/lithium/forum/models.py/Thread.save/original