      def check_permissions(self):
          if not self.permissions:
              return
  
          auth = self.auth
          for permitter_cls in self.permitters:
              permitter = permission_cls(self)
              permitter.permit(auth)
  
      def _authenticate(self):
          for authenticator_cls in self.authenticators:
              authenticator = authenticator_cls(self)
              auth = authenticator.authenticate(self.request)
 
</s> remove     def _authenticate(self):
        for authenticator_cls in self.authenticators:
            authenticator = authenticator_cls(self)
            auth = authenticator.authenticate(self.request)
            if auth:
                return auth
        return None
 </s> add  </s> remove         self.mixin = mixin
 </s> add         self.view = view </s> remove     def __init__(self, mixin):
 </s> add     def __init__(self, view): </s> remove     # Map standard HTTP methods to function calls
    callmap = { 'GET': 'get', 'POST': 'post', 
                'PUT': 'put', 'DELETE': 'delete' }

    def get(self, request, *args, **kwargs):
        """Must be subclassed to be implemented."""
        self.not_implemented('GET')


    def post(self, request, *args, **kwargs):
        """Must be subclassed to be implemented."""
        self.not_implemented('POST')


    def put(self, request, *args, **kwargs):
        """Must be subclassed to be implemented."""
        self.not_implemented('PUT')


    def delete(self, request, *args, **kwargs):
        """Must be subclassed to be implemented."""
        self.not_implemented('DELETE')
 </s> add     @property
    def allowed_methods(self):
        return [method.upper() for method in self.http_method_names if hasattr(self, method)]
        for permission_cls in self.permissions:
            permission = permission_cls(self)
            if not permission.has_permission(self.auth):
                raise ErrorResponse(status.HTTP_403_FORBIDDEN,
                                   {'detail': 'You do not have permission to access this resource. ' +
                                    'You may need to login or otherwise authenticate the request.'})                

      def check_permissions(self):
          if not self.permissions:
              return
  
        for permission_cls in self.permissions:
            permission = permission_cls(self)
            if not permission.has_permission(self.auth):
                raise ErrorResponse(status.HTTP_403_FORBIDDEN,
                                   {'detail': 'You do not have permission to access this resource. ' +
                                    'You may need to login or otherwise authenticate the request.'})                

        for permission_cls in self.permissions:
            permission = permission_cls(self)
            if not permission.has_permission(self.auth):
                raise ErrorResponse(status.HTTP_403_FORBIDDEN,
                                   {'detail': 'You do not have permission to access this resource. ' +
                                    'You may need to login or otherwise authenticate the request.'})                

        for permission_cls in self.permissions:
            permission = permission_cls(self)
            if not permission.has_permission(self.auth):
                raise ErrorResponse(status.HTTP_403_FORBIDDEN,
                                   {'detail': 'You do not have permission to access this resource. ' +
                                    'You may need to login or otherwise authenticate the request.'})                

        for permission_cls in self.permissions:
            permission = permission_cls(self)
            if not permission.has_permission(self.auth):
                raise ErrorResponse(status.HTTP_403_FORBIDDEN,
                                   {'detail': 'You do not have permission to access this resource. ' +
                                    'You may need to login or otherwise authenticate the request.'})                

  
      def _authenticate(self):
          for authenticator_cls in self.authenticators:
              authenticator = authenticator_cls(self)
              auth = authenticator.authenticate(self.request)
keep keep keep keep replace replace replace replace keep keep keep keep keep
 Generic permissions added, allowed_methods and anon_allowed_methods now defunct, dispatch now mirrors View.dispatch more nicely 
djangorestframework/mixins.py