public ApplicationServiceResponse RegisterUser(RegisterViewModel model)
        {
            model.Validate();
            if (!model.IsValid)
            {
                return(BadRequest(model.GetValidationMessagesList()));
            }
            var user     = _mapper.Map <User>(model);
            var messages = _userBusiness.CreateUser(user, model.Password);

            if (messages != null)
            {
                return(BadRequest(messages));
            }
            return(Ok());
        }