Make sure there is at least a translation has been filled in. If a
        default language has been specified, make sure that it exists amongst
        translations.

def clean(self):
        """
        Make sure there is at least a translation has been filled in. If a
        default language has been specified, make sure that it exists amongst
        translations.
        """

        # First make sure the super's clean method is called upon.
        super(TranslationFormSet, self).clean()

        if settings.HIDE_LANGUAGE:
            return

        if len(self.forms) > 0:
            # If a default language has been provided, make sure a translation
            # is available

            if settings.DEFAULT_LANGUAGE and not any(self.errors):
                # Don't bother validating the formset unless each form is
                # valid on its own. Reference:
                # http://docs.djangoproject.com/en/dev/topics/forms/formsets/#custom-formset-validation

                for form in self.forms:
                    language_code = form.cleaned_data.get(
                        'language_code', None
                    )

                    if language_code == settings.DEFAULT_LANGUAGE:

                        # All is good, don't bother checking any further
                        return

                raise forms.ValidationError(_(
                    'No translation provided for default language \'%s\'.'
                ) % settings.DEFAULT_LANGUAGE)

        else:
            raise forms.ValidationError(
                _('At least one translation should be provided.')
            )