Fix response code checks