Fix using html_safe for non-String objects