Add some validations to arguments.