human
I wrote the below code

    @functools.wraps(view_func, assigned=available_attrs(view_func))
    def dec(request, *args, **kwargs):
        if dashboard:
            request.horizon['dashboard'] = dashboard
        if panel:
            request.horizon['panel'] = panel
        return view_func(request, *args, **kwargs)
    return dec

What's a good function header?
assistant
#Here's a good function header.

def _current_component(view_func, dashboard=None, panel=None):