summaryrefslogtreecommitdiff
path: root/app/controllers/projects/blob_controller.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-10-21 18:06:29 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-10-21 18:06:29 +0000
commitf1bb2a307e9b125a8ee0be3728cb0d1baa21a3d4 (patch)
tree154817af5e3f1b134be08ef22d1926edf87ab74f /app/controllers/projects/blob_controller.rb
parentad1e4b8fb8104b642fa79ed34fd144bc2bed8a19 (diff)
downloadgitlab-ce-f1bb2a307e9b125a8ee0be3728cb0d1baa21a3d4.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers/projects/blob_controller.rb')
-rw-r--r--app/controllers/projects/blob_controller.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/controllers/projects/blob_controller.rb b/app/controllers/projects/blob_controller.rb
index 7c3d43fb49a..205ec288ce9 100644
--- a/app/controllers/projects/blob_controller.rb
+++ b/app/controllers/projects/blob_controller.rb
@@ -7,6 +7,7 @@ class Projects::BlobController < Projects::ApplicationController
include RendersBlob
include NotesHelper
include ActionView::Helpers::SanitizeHelper
+ include RedirectsForMissingPathOnTree
prepend_before_action :authenticate_user!, only: [:edit]
around_action :allow_gitaly_ref_name_caching, only: [:show]
@@ -119,7 +120,7 @@ class Projects::BlobController < Projects::ApplicationController
end
end
- return render_404
+ return redirect_to_tree_root_for_missing_path(@project, @ref, @path)
end
end