original_docstring: 
      Decorator for views that checks that the user is logged in and that
      they are a team member for a particular event. Returns 404 otherwise.
      
docstring: Decorator for views that checks that the user is logged in and that
  they are a team member for a particular event. Returns 404 otherwise.
docstring_tokens: Decorator for views that checks that the user is logged in and that they are a team member for a particular event . Returns 404 otherwise .
code: def organiser_only(function):
      """
      Decorator for views that checks that the user is logged in and that
      they are a team member for a particular event. Returns 404 otherwise.
      """
  
      @wraps(function)
      def decorator(request, *args, **kwargs):
          city = kwargs.get('city')
  
          if not city:
              raise ValueError(
                  _('"City" slug must be present to user this decorator.')
              )
  
          if not request.user.is_authenticated:
              return redirect('core:event', city)
  
          event = get_event(city, request.user.is_authenticated, False)
          if event and (request.user in event.team.all() or request.user.is_superuser):
              return function(request, *args, **kwargs)
          return HttpResponseNotFound()
      return decorator
code_tokens: def organiser_only ( function ) : @ wraps ( function ) def decorator ( request , * args , ** kwargs ) : city = kwargs . get ( 'city' ) if not city : raise ValueError ( _ ( '"City" slug must be present to user this decorator.' ) ) if not request . user . is_authenticated : return redirect ( 'core:event' , city ) event = get_event ( city , request . user . is_authenticated , False ) if event and ( request . user in event . team . all ( ) or request . user . is_superuser ) : return function ( request , * args , ** kwargs ) return HttpResponseNotFound ( ) return decorator
short_docstring: Decorator for views that checks that the user is logged in and that
  they are a team member for a particular event.
short_docstring_tokens: Decorator for views that checks that the user is logged in and that they are a team member for a particular event .
comment: """
      Decorator for views that checks that the user is logged in and that
      they are a team member for a particular event. Returns 404 otherwise.
      """