Improvements to html sanitizer