mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-01-24 08:14:16 +03:00
Set a view function's __module__ value to the WrappedAPIView object's __module__ (#4465)
This commit is contained in:
parent
07efbdb45e
commit
5df54a711f
|
@ -55,6 +55,7 @@ def api_view(http_method_names=None):
|
|||
setattr(WrappedAPIView, method.lower(), handler)
|
||||
|
||||
WrappedAPIView.__name__ = func.__name__
|
||||
WrappedAPIView.__module__ = func.__module__
|
||||
|
||||
WrappedAPIView.renderer_classes = getattr(func, 'renderer_classes',
|
||||
APIView.renderer_classes)
|
||||
|
|
Loading…
Reference in New Issue
Block a user