refactor validation to support credit card update