diff --git a/AUTHORS b/AUTHORS
index 9627882..a0cf084 100644
a
|
b
|
answer newbie questions, and generally made Django that much better:
|
511 | 511 | Cheng Zhang |
512 | 512 | Glenn Maynard <glenn@zewt.org> |
513 | 513 | bthomas |
| 514 | Pascal Hartig <phartig@rdrei.net> |
514 | 515 | |
515 | 516 | A big THANK YOU goes to: |
516 | 517 | |
diff --git a/django/middleware/doc.py b/django/middleware/doc.py
index 4f91503..176cf63 100644
a
|
b
|
class XViewMiddleware(object):
|
15 | 15 | if request.method == 'HEAD' and (request.META.get('REMOTE_ADDR') in settings.INTERNAL_IPS or |
16 | 16 | (request.user.is_active and request.user.is_staff)): |
17 | 17 | response = http.HttpResponse() |
18 | | response['X-View'] = "%s.%s" % (view_func.__module__, view_func.__name__) |
| 18 | |
| 19 | if hasattr(view_func, '__class__'): |
| 20 | name = view_func.__class__.__name__ |
| 21 | else: |
| 22 | name = view_func.__name__ |
| 23 | |
| 24 | response['X-View'] = "%s.%s" % (view_func.__module__, name) |
19 | 25 | return response |