That's exactly why there is a check for &/&amp;

Sometimes URLs can contain &, sometimes &amp; and I think assets_version should be appended correctly to both URLs without altering syntax. It would look bad if URL has mix of escaped and unescaped ampersands.