#39989
tumblingmug
Participant

I’d confirm that there is a hidden bug in both front.js and front.min.js
However, it seems only to appear if we remove the close button with the id “cn-close-notice” (like I did).

In front.js you assign on line 397:
closeIcon = document.getElementById( 'cn-close-notice' );

Then, on lines 502/503 we read this:

if ( closeIcon !== 'null' ) {
	closeIcon.addEventListener( 'click', function ( e ) {

Here’s the small hidden bug since in case of the closing button’s absence the closeIcon variable will contain null but not the string null. Therefore we’d love to see a change here on line 502 to:
if ( closeIcon !== null ) {
instead and the minified version recreated after that.

Thanks for the plugin!