private CalendarSettings GetSettings() { try { string json = _settingsFileReader.ReadJson(); CalendarSettings settings = JsonConvert.DeserializeObject <CalendarSettings>(json); return(settings); } catch { return(new CalendarSettings()); } }
public CalendarSettingsProvider(ISettingsFileReader settingsFileReader) { _settingsFileReader = settingsFileReader; _settings = GetSettings(); }