ankane / ahoy_email

First-party email analytics for Rails
MIT License
1.11k stars 137 forks source link

Track utm_params breaks links with nested content #148

Closed mnort9 closed 3 years ago

mnort9 commented 3 years ago

When using track utm_params: true, it seems to remove nested link content to outside the link tag. Example:

track utm_params: false

<a href="https://google.com">
  <img src="...">
</a>

track utm_params: true

<a href="https://google.com?utm_source=...">
</a>
<img src="...">
ankane commented 3 years ago

Hey @mnort9, I'd double check that the markup isn't malformed beforehand. If that's not the issue, can you create a test case like the one in the commit above to reproduce?

ankane commented 3 years ago

Closing due to no response