Archived topic
Updated to Latest GP Version- Caused many New errors in Lighthouse
3 replies · Started by Melissa on December 8, 2021
I updated GeneratePress this morning to the latest version, and now I am receiving several different errors that I wasn't getting before.
Description
script-src directive is missing. This can allow the execution of unsafe scripts.
script-src
Missing object-src allows the injection of plugins that execute unsafe scripts. Consider setting object-src to 'none' if you can.
object-src
and
Charset declaration is missing or occurs too late in the HTML
How do I remedy these issues?
Hi there,
can you share a link to your site where we can see the problems as updating GP shouldn't have caused that.
Yes Sir, thank you, I've added the link in the private info area.
Ok so:
1.script-src Can you disable WP Rocket and Autoptimize and retest the site, if it still raises an issue temporarily disable any adverts as there are multiple 3rd party scripts that could be causing this.
2. this: Charset declaration is missing or occurs too late in the HTML - see here:
https://www.screencast.com/t/DuroPpaldn
WP Rocket is injecting its lazy loading scripts before the charset meta tag ( highlighted in green ). Which looks to be the issue - if i disable WP Rocket by adding ?nowprocket to the URL when running the lighthouse test that warning is not reported,