def distributed_server_only(handler):
 def distributed_server_only_wrapper_fn(*args, **kwargs):
  if settings.CENTRAL_SERVER:
   raise Http404(_('This path is only available on distributed servers.'))
  return handler(*args, **kwargs)
 return distributed_server_only_wrapper_fn

def distributed_server_only ( handler ) : def distributed_server_only_wrapper_fn ( * args , ** kwargs ) : if settings . CENTRAL_SERVER : raise Http404 ( _ ( 'This path is only available on distributed servers.' ) ) return handler ( * args , ** kwargs ) return distributed_server_only_wrapper_fn
assert-like decorator that marks a function for use only on a distributed server .