'Ensure based_on is valid & police is_ready/is_approved invariant.'

def clean(self):

    try:
        (self.document and self.document.original)
    except Document.DoesNotExist:
        self.based_on = None
    else:
        (based_on, is_clean) = self._based_on_is_clean()
        if (not is_clean):
            old = self.based_on
            self.based_on = based_on
            raise ValidationError((_('A    revision    must    be    based    on    the    English    article.    Revision    ID    %(id)s    does    not    fit    this    criterion.') % dict(id=old.id)))
    if (not self.can_be_readied_for_localization()):
        self.is_ready_for_localization = False
