def to_unicode(text):
if not text or isinstance(text, unicode if PY2 else str):<EOL><INDENT>return text<EOL><DEDENT>try:<EOL><INDENT>return text.decode("<STR_LIT>")<EOL><DEDENT>except UnicodeError:<EOL><INDENT>try:<EOL><INDENT>return text.decode("<STR_LIT>")<EOL><DEDENT>except UnicodeError:<EOL><INDENT>return text<EOL><DEDENT><DEDENT>
Return a decoded unicode string.
        False values are returned untouched.