Skip to content

Commit

Permalink
Only log debug when debug is set.
Browse files Browse the repository at this point in the history
  • Loading branch information
jbriggs-zvelo committed May 7, 2015
1 parent 5831040 commit 8886541
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion envetcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,9 @@ func Set(service string) error {
return err
}

log.Printf("[DEBUG] envetcd: %v => %v\n", "ETCD_ENDPOINT", etcdEndpoint)
if keyPairs["LOG_LEVEL"] == "DEBUG" {
log.Printf("[DEBUG] envetcd: %v => %v\n", "ETCD_ENDPOINT", etcdEndpoint)
}
keyPairs["ETCD_ENDPOINT"] = etcdEndpoint

for key, value := range keyPairs {
Expand Down

0 comments on commit 8886541

Please sign in to comment.