dumb mistake with too many boolean ops