From https://css-tricks.com/snippets/javascript/check-if-function-exists-before-calling/
// no error checking (yourFunctionName || Function)(); // debugging, maybe on Firefox (yourFunctionName || console.error)(); // debugging on Chrome (yourFunctionName || function(){ console.error(arguments) })();