use of invariant has been an error for a while

don't know just when it happened.