3636
3737def wrap_set_tracer_provider (wrapped , instance , args , kwargs ):
3838 settings = global_settings ()
39-
39+
4040 if not settings .otel_bridge .enabled :
4141 return wrapped (* args , ** kwargs )
4242
@@ -51,7 +51,7 @@ def wrap_set_tracer_provider(wrapped, instance, args, kwargs):
5151
5252def wrap_get_tracer_provider (wrapped , instance , args , kwargs ):
5353 settings = global_settings ()
54-
54+
5555 if not settings .otel_bridge .enabled :
5656 return wrapped (* args , ** kwargs )
5757
@@ -84,10 +84,10 @@ def wrap_get_current_span(wrapped, instance, args, kwargs):
8484 # Do not allow the wrapper to continue if
8585 # the Hybrid Agent setting is not enabled
8686 settings = transaction .settings or global_settings ()
87-
87+
8888 if not settings .otel_bridge .enabled :
8989 return wrapped (* args , ** kwargs )
90-
90+
9191 # If a NR trace does exist, check to see if the current
9292 # OTel span corresponds to the current NR trace. If so,
9393 # return the original function's result.
@@ -140,10 +140,10 @@ def wrap_start_internal_or_server_span(wrapped, instance, args, kwargs):
140140 # Do not allow the wrapper to continue if
141141 # the Hybrid Agent setting is not enabled
142142 settings = global_settings ()
143-
143+
144144 if not settings .otel_bridge .enabled :
145145 return wrapped (* args , ** kwargs )
146-
146+
147147 bound_args = bind_args (wrapped , args , kwargs )
148148 context_carrier = bound_args .get ("context_carrier" , None )
149149 attributes = bound_args .get ("attributes" , {})
0 commit comments