public void CreateServiceGymViewModel(ServiceGymViewModel serviceGymViewModel) { try { if (serviceGymViewModel != null) { var serviceGym = _converterServiceGymViewModelToServiceGym.Map(serviceGymViewModel); _serviceGymRepository.CreateServiceGym(serviceGym); //_logger.LogInformation("Service Gym Created"); } } #pragma warning disable CS0168 // La variable 'e' se ha declarado pero nunca se usa catch (Exception e) #pragma warning restore CS0168 // La variable 'e' se ha declarado pero nunca se usa { //_logger.LogWarning("Error el modelo llega nulo, message: " + e.Message); } }