code: def pass_obj(
      f: "t.Callable[te.Concatenate[t.Any, P], R]",
  ) -> "t.Callable[P, R]":
      """Similar to :func:`pass_context`, but only pass the object on the
      context onwards (:attr:`Context.obj`).  This is useful if that object
      represents the state of a nested system.
      """
  
      def new_func(*args: "P.args", **kwargs: "P.kwargs") -> "R":
          return f(get_current_context().obj, *args, **kwargs)
  
      return update_wrapper(new_func, f)
  
imports: import inspect
  import types
  import typing
  from functools import update_wrapper
  from gettext import gettext
  from .core import Argument
  from .core import Command
  from .core import Context
  from .core import Group
  from .core import Option
  from .core import Parameter
  from .globals import get_current_context
  from .utils import echo
label_desc: Use image node_id 2 for calling a global function with example usage: pass_obj(f) and returns: update_wrapper, f