X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/e9622f371ad4d75f0a0b5ee9480fae779dd63156..707ed2964a24ebe940ae440af22fdcb56781fcbd:/services/api/app/controllers/static_controller.rb diff --git a/services/api/app/controllers/static_controller.rb b/services/api/app/controllers/static_controller.rb index 6ee46e0e4e..594dc43629 100644 --- a/services/api/app/controllers/static_controller.rb +++ b/services/api/app/controllers/static_controller.rb @@ -1,9 +1,13 @@ +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: AGPL-3.0 + class StaticController < ApplicationController respond_to :json, :html skip_before_filter :find_object_by_uuid skip_before_filter :render_404_if_no_object - skip_before_filter :require_auth_scope, :only => [ :home, :login_failure ] + skip_before_filter :require_auth_scope, only: [:home, :empty, :login_failure] def home respond_to do |f| @@ -11,7 +15,7 @@ class StaticController < ApplicationController if Rails.configuration.workbench_address redirect_to Rails.configuration.workbench_address else - render_not_found "Path not found." + render_not_found "Oops, this is an API endpoint. You probably want to point your browser to an Arvados Workbench site instead." end end f.json do @@ -20,4 +24,8 @@ class StaticController < ApplicationController end end + def empty + render text: "-" + end + end