public void Create(User entity)
 {
     try
     {
         _loggerService.Trace("Add User started");
         entity.UserPhotoId = 1;
         _repository.Add(entity);
         _unitOfWork.Commit();
         _loggerService.Trace("Add User finished");
     }
     catch (Exception exeption)
     {
         _loggerService.Error(exeption.Message);
         throw;
     }
 }
 public void Delete(User entity)
 {
     try
     {
         _loggerService.Trace("Delete User started");
         var user = GetById(entity.Id);
         _repository.Delete(user);
         _unitOfWork.Commit();
         _loggerService.Trace("Delete User finished");
     }
     catch (Exception exeption)
     {
         _loggerService.Error(exeption.Message);
         throw;
     }
 }
 public void Update(User entity)
 {
     try
     {
         _loggerService.Trace("Update User started");
         _repository.Update(entity);
         _unitOfWork.Commit();
         _loggerService.Trace("Update User finished");
     }
     catch (Exception exeption)
     {
         _loggerService.Error(exeption.Message);
         throw;
     }
 }