Fix some view logic