Adds api/convert to return HTML document from legacy format + Saves attached images when just converting to HTML, without creating a text + Returns nb of detached and removed commentswhen updating text.
from django.utils.translation.trans_real import translation
def translate_to(value, language_code):
t = translation(language_code)
return getattr(t, 'gettext')(value)