So I the following code is my greasemonkey script:
When the first condition is true, the code inside executes perfectly. Otherwise, nothing is getting run. Note that the same thing happens if I use an "else" instead of the second "if". Note too, if the first condition is true, then "got past" gets displayed, but if it's false, then even that line doesn't get executed.
var msg = document.body.innerHTML;
if(msg.match(/Big monster/gi).length > 0)
if(msg.match(/Big monster/gi).length == 0)
//Do other stuff