human
Solve the following python programming problem given the following code:
def link(endpoint = None, is_for_list = False, **kwargs) : 
    '
    Used to mark a method on a ViewSet that should be routed for GET requests.
    ' 
    msg = 'link is pending deprecation. Use detail_route instead.' 
    warnings.warn (endpoint, PendingDeprecationWarning, stacklevel = 2) 
    def decorator(func) : 
        func.bind_to_methods = ['get'] 
        func.kwargs = kwargs 
        func.endpoint = (endpoint or func.__name__) 
        func.is_for_list = is_for_list 
        return func 
return decorator 

    
    

    Fix the buggy line: warnings.warn (endpoint, PendingDeprecationWarning, stacklevel = 2)
assistant
#Here is Python code to fix the buggy line: warnings.

warnings.warn (msg, PendingDeprecationWarning, stacklevel = 2)