Refactor User validation into the model