public async Task UpdateAsync(UserProfileUpdateInfo updateCommand)
        {
            var userProfile = await EnsureGetUserProfile(updateCommand.UserProfileId);

            userProfile.FirstName  = updateCommand.FirstName;
            userProfile.MiddleName = updateCommand.MiddleName;
            userProfile.LastName   = updateCommand.LastName;

            await userProfileRepository.UpdateAsync(userProfile);

            await unitOfWork.CompleteAsync();
        }
        public async Task <IActionResult> Put(int userProfileId, [FromBody] UserProfileUpdateInfo updateCommandRequest)
        {
            if (!userProfileService.Exists(userProfileId))
            {
                return(NotFound(userProfileId));
            }

            updateCommandRequest.UserProfileId = userProfileId; //Ensure same Id
            await userProfileService.UpdateAsync(updateCommandRequest);

            return(Ok());
        }