def clean(self):
        cleaned_data = super(AbstractEntryBaseAdminForm, self).clean()
        if 'slug' not in cleaned_data or 'publication_date' not in cleaned_data:
            return cleaned_data

        try:
            self.validate_unique_slug(cleaned_data)
        except __HOLE__ as e:
            self._errors['slug'] = self.error_class(e.messages)

        return cleaned_data
dataset/ETHPy150Open edoburu/django-fluent-blogs/fluent_blogs/admin/forms.py/AbstractEntryBaseAdminForm.clean