fixing some things related to validation failure