This is a call that is triggered by a JavaScript error on your front-end, and is used to notify you of the existence of such an error. It is limited to 5 requests. This count expires after a while.
Possibly your setup continuously clears transients, causing the counter to get reset constantly.
Please try the following:
Add this line of code:
set_transient( 'cmplz_checked_for_js_count', 20, YEAR_IN_SECONDS);
To your theme’s functions.php or to a mu-plugin. Then refresh.
It will set the count to twenty. If the issue returns after removing the line again, there is an issue with the persistence of your transient. You can then leave the line in, or take a look at your caching configuration.
Let me know if that helps!
Did this resolve the issue for you?
Hi @rogierlankhorst
We are experiencing the same issue, server gets unresponsive. We rely heavy on caching and would like to know how to disable this check completely?
edit: found out it was caused by a javascript error on scroll.. Would still like to disable this completely!
-
This reply was modified 3 years, 8 months ago by
actieveling.
Please update to https://github.com/really-Simple-Plugins/complianz-gdpr
The detection of javascript errors is limited to SCRIPT_DEBUG only.
This will be released in about a week.
@rogierlankhorst Thanks, really need a quick fix now and I dont wamt to disable the whole plugin for this customer.
Would this work for now as a temp solution?
set_transient( 'cmplz_checked_for_js_count' , 100 );
Seeing how it is checked in https://github.com/Really-Simple-Plugins/complianz-gdpr/blob/32d6a2f4f1846a2992c3585e1f6f642b085be06f/cookie/class-cookie-admin.php#L185-L188
@actieveling as mentioned above, you can use:
set_transient( ‘cmplz_checked_for_js_count’, 20, YEAR_IN_SECONDS);