Skip to content
This repository has been archived by the owner on Sep 22, 2023. It is now read-only.

Commit

Permalink
Fix bool (#3)
Browse files Browse the repository at this point in the history
* support initializing without a env key

* update readme with how to contribute

* set a fallback key

* dont contribute

* configurable dep tracking

* add env options

* set configurable env vars

* Fix the bool

* Flip logic
  • Loading branch information
sgrieb-gp authored Sep 2, 2020
1 parent 99192fc commit 93b1c31
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ import { EventTelemetry, DependencyTelemetry, ExceptionTelemetry, MetricTelemetr
const clientKey = (process.env.APPINSIGHTS_INSTRUMENTATIONKEY || "fake")

appInsights.setup(clientKey)
.setAutoDependencyCorrelation(<boolean>(process.env.AI_AUTO_DEPENDENCY_CORRELATE ? process.env.AI_AUTO_DEPENDENCY_CORRELATE : true))
.setAutoDependencyCorrelation(<boolean>(process.env.AI_AUTO_DEPENDENCY_CORRELATE === 'false' ? false : true))
.setAutoCollectRequests(true)
.setAutoCollectPerformance(true, true)
.setAutoCollectExceptions(true)
.setAutoCollectDependencies(<boolean>(process.env.AI_AUTOCOLLECT_DEPENDENCIES ? process.env.AI_AUTOCOLLECT_DEPENDENCIES : true))
.setAutoCollectDependencies(<boolean>(process.env.AI_AUTOCOLLECT_DEPENDENCIES === 'false' ? false : true))
.setAutoCollectConsole(true)
.setUseDiskRetryCaching(true)
.setSendLiveMetrics(false)
Expand Down

0 comments on commit 93b1c31

Please sign in to comment.