Ah, I didn't catch that, now I understand.

Maybe a comment somewhere to explain that, and I'd still appreciate a re-work of that function's structure, specifically checking for the page types we don't want instead of checking for the page types we do want.