Upgraded to discourse version 2.8.0.beta7 & beta8 causing data loss of </head> section scripts that hasn't been loaded most times in browser

Do you have a proxy (e.g. cloudflare) in front of your site? If so, please try disabling it.