Clean up validation code for COOK-4337

Specifically, split validate_nameable into two methods since the two use cases didn't share any code. Additionally, remove duplicates of validate_numeric() code present in validate_nameable.
Merge pull request #1 from tiaz/validation-cleanup

Clean up validation code for COOK-4337