Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions rest_framework/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,11 +372,6 @@ def initial(self, request, *args, **kwargs):
"""
self.format_kwarg = self.get_format_suffix(**kwargs)

# Ensure that the incoming request is permitted
self.perform_authentication(request)
self.check_permissions(request)
self.check_throttles(request)

# Perform content negotiation and store the accepted info on the request
neg = self.perform_content_negotiation(request)
request.accepted_renderer, request.accepted_media_type = neg
Expand All @@ -385,6 +380,11 @@ def initial(self, request, *args, **kwargs):
version, scheme = self.determine_version(request, *args, **kwargs)
request.version, request.versioning_scheme = version, scheme

# Ensure that the incoming request is permitted
self.perform_authentication(request)
self.check_permissions(request)
self.check_throttles(request)

def finalize_response(self, request, response, *args, **kwargs):
"""
Returns the final response object.
Expand Down