human
I wrote the below code

    @wraps(view_func)
    def inner(request, *args, **kwargs):
        course_key = (kwargs.get('course_key_string') or kwargs.get('course_id'))
        if (course_key is not None):
            try:
                CourseKey.from_string(course_key)
            except InvalidKeyError:
                raise Http404
        response = view_func(request, *args, **kwargs)
        return response
    return inner

What's a good function header?

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

def ensure_valid_course_key(view_func):