def METHOD_NAME(decorated_function):
    def call_function(*args, **kwargs):
        if hasattr(decorated_function, "__self__"):
            function(decorated_function.__self__, *args, **kwargs)
        else:
            function(*args, **kwargs)
        return decorated_function(*args, **kwargs)
    return call_function