Skip to content

Commit

Permalink
Fix code sample in otel.GetTraceProvider (#2147)
Browse files Browse the repository at this point in the history
  • Loading branch information
ymotongpoo authored Jul 30, 2021
1 parent 2b1bb29 commit 39acab3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions trace.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ func Tracer(name string, opts ...trace.TracerOption) trace.Tracer {
// If none is registered then an instance of NoopTracerProvider is returned.
//
// Use the trace provider to create a named tracer. E.g.
// tracer := global.GetTracerProvider().Tracer("example.com/foo")
// tracer := otel.GetTracerProvider().Tracer("example.com/foo")
// or
// tracer := global.Tracer("example.com/foo")
// tracer := otel.Tracer("example.com/foo")
func GetTracerProvider() trace.TracerProvider {
return global.TracerProvider()
}
Expand Down

0 comments on commit 39acab3

Please sign in to comment.