Inline script wp-polyfill-js error if logged in
-
Hello!
Plugin just updated again. And i going to edit your code to fix problems.
Console error: missing )This happen because you adding AS IS ‘ when need to use ” in inline script code.
Look at screen: https://drive.google.com/file/d/1MEOYohKEMA8cHoC5OWlL3MqAwFH8vvLQ/view?usp=sharing
( 'fetch' in window ) || document.write( '<script defer='defer' src="---/blog/tools/js/dist/vendor/wp-polyfill-fetch.min.js?...
you adding single quotes. but it breakes script.
I go to file: /wp-content/plugins/clearfy_package/plugins/async-javascript/includes/classes/class-configurate-async-javascript.php
need to change line 193
$tag = str_replace( 'src=', $this->method . "='" . $this->method . "' src=", $tag );
to this + add line 194:
$tag = str_replace( 'src="', $this->method . '="' . $this->method . '" src="', $tag ); $tag = str_replace( "src='", $this->method . "='" . $this->method . "' src='", $tag );
to use it in every cases of single or double quotes.
please add fix to plugin.
i don’t whant to edit code every time you updated.
- The topic ‘Inline script wp-polyfill-js error if logged in’ is closed to new replies.