What modifications are made to the content of HTML mails

If we determine that we need to use an HTML template, then we need to slightly modify the content of the mail. Most mails in Joomla are sent as plain-text. But if you are using an HTML template you want this plain text to be properly formatted. So that is why when we need to send an HTML template and we find out that the text is in plain-text we parse it and add <br /> where necessary & we also change HTML links to <a href="/html link">html link</a> . Those small modifications make sure that the mail will look fine in the user's inbox.