Added some field validation