Don't you want to check if has_instructor_access is True or False? And is this the appropriate HttpResponse? (I'm not sure; would it be 403?)