#NEWLINE# def render_text( text , language = None ) : #NEWLINE# #INDENT# '\n    Render the text, reuses the template filters provided by Django.\n    ' #NEWLINE# text_filter = SUPPORTED_LANGUAGES . get ( language , None ) #NEWLINE# if ( not text_filter ) : #NEWLINE# #INDENT# raise ImproperlyConfigured ( 'markup filter does not exist: {0}. Valid options are: {1}' . format ( text_filter , ', ' . join ( list ( SUPPORTED_LANGUAGES . keys ( ) ) ) ) ) #NEWLINE# #UNINDENT# return text_filter ( text )