small update to add validation