I struggle with a javascript error, that I cannot get rid of: Uncaught TypeError: Failed to execute 'addEventListener' on 'EventTarget': The callback provided as parameter 2 is not an object.
This is the script, that is used in a cookie consent module after the tag:
window.addEventListener("load", setTimeout( function(){
window.cookieconsent.initialise({
"palette": { "popup": {"background": "#DCDCDC"},
"button": {"background": "#9bba44"}
},
"position": "bottom-right",
"content": { "message": "We use cookies.",
"accept": "Accept all",
"deny": "Decline all",
"link": "Find out more." }
})
}, 3000));
</script>
If needed I can look into cookieconsent.initialise, but the error may be something else, more trivial to anyone with experience. What is the second parameter here?