Sorry, I'm an idiot

...Or at least I should know better than to submit pull requests after dinner-time. I was doing straight boolean logic rather than EE's weird 1/0-based return values, which worked in my use-case but not overall. How embarrassing.... 

Here's the fixed version.