There was a wrong error check.