private static ILogglyConfig FromAppConfig() { var config = new LogglyConfig(); config.CustomerToken = LogglyAppConfig.Instance.CustomerToken; config.ThrowExceptions = LogglyAppConfig.Instance.ThrowExceptions; config.ApplicationName = new ApplicationNameProvider().GetName(); config.IsEnabled = LogglyAppConfig.Instance.IsEnabled; if (LogglyAppConfig.Instance.HasTagConfig) { config.TagConfig.Tags.AddRange(LogglyAppConfig.Instance.Tags.Simple.Cast <ITag>().ToList()); config.TagConfig.Tags.AddRange(LogglyAppConfig.Instance.Tags.GetComplexTags()); } config.Transport = LogglyAppConfig.Instance.Transport.GetCoercedToValidConfig(); config.Search = LogglyAppConfig.Instance.Search; return(config); }
private static ILogglyConfig FromAppConfig() { var config = new LogglyConfig(); config.CustomerToken = LogglyAppConfig.Instance.CustomerToken; config.ThrowExceptions = LogglyAppConfig.Instance.ThrowExceptions; config.ApplicationName = new ApplicationNameProvider().GetName(); config.IsEnabled = LogglyAppConfig.Instance.IsEnabled; if (LogglyAppConfig.Instance.HasTagConfig) { config.Tags.SimpleTags.AddRange(LogglyAppConfig.Instance.Tags.Simple.Cast<ISimpleTag>().ToList()); config.Tags.ComplexTags.AddRange(LogglyAppConfig.Instance.Tags.GetComplexTags()); } config.Transport = LogglyAppConfig.Instance.Transport.GetCoercedToValidConfig(); config.Search = LogglyAppConfig.Instance.Search; return config; }