Fix invaldiateCache checks.