Already done that. My code looks like this:
` function sanitize($text, $striptags=false, $spec=false) {
//balance and neutralize unsafe tags.
//$text = Format::safe_html($text, array('spec' => $spec));
//above line commented on 2020-02-05 to avoid stripping of <111111>
$text = self::localizeInlineImages($text);
//If requested - strip tags with decoding disabled.
return $striptags?Format::striptags($text, false):$text;
}`
This is working fine but only for text/html emails.
If I get an email with content-type = text/plain, then the <xxx> is still stripping.