public SmsLogger(ISettingRepository settingRepository, IEmailService emailService) { Argument.NotNull(settingRepository, "settingRepository"); Argument.NotNull(emailService, "emailService"); _emailService = emailService; _settings = settingRepository.GetOrDefault <SmsLoggerSettings>(); if (_settings == null) { throw new InvalidOperationException("Settings for sms logger were not found."); } }
public SmsLogger(ISettingRepository settingRepository, IEmailService emailService) { Argument.NotNull(settingRepository, "settingRepository"); Argument.NotNull(emailService, "emailService"); _emailService = emailService; _settings = settingRepository.GetOrDefault<SmsLoggerSettings>(); if (_settings == null) { throw new InvalidOperationException("Settings for sms logger were not found."); } }