summaryrefslogtreecommitdiff
path: root/app/controllers/snippets_controller.rb
diff options
context:
space:
mode:
authorKamil Trzcinski <ayufan@ayufan.eu>2015-09-15 22:40:35 +0200
committerKamil Trzcinski <ayufan@ayufan.eu>2015-09-15 22:40:35 +0200
commite21deaee8ee0d453bf899c1b3fb46262cc60dab9 (patch)
tree59b04c9cb1c8ce6c510a78ee787fb31817619835 /app/controllers/snippets_controller.rb
parent7e2dbcbe0915cfd75e91d78e943c153f284df37d (diff)
parent0ad669bb5ba08d012d3daa50b51a3a6b069e3e83 (diff)
downloadgitlab-ce-e21deaee8ee0d453bf899c1b3fb46262cc60dab9.tar.gz
Merge remote-tracking branch 'origin/master' into ci-and-ce-sitting-in-a-tree-k-i-s-s-i-n-g
# Conflicts: # Gemfile.lock
Diffstat (limited to 'app/controllers/snippets_controller.rb')
-rw-r--r--app/controllers/snippets_controller.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/app/controllers/snippets_controller.rb b/app/controllers/snippets_controller.rb
index 8e7e45c781f..9f9f9a92f11 100644
--- a/app/controllers/snippets_controller.rb
+++ b/app/controllers/snippets_controller.rb
@@ -24,13 +24,9 @@ class SnippetsController < ApplicationController
scope: params[:scope] }).
page(params[:page]).per(PER_PAGE)
- if @user == current_user
- render 'current_user_index'
- else
- render 'user_index'
- end
+ render 'index'
else
- @snippets = SnippetsFinder.new.execute(current_user, filter: :all).page(params[:page]).per(PER_PAGE)
+ redirect_to(current_user ? dashboard_snippets_path : explore_snippets_path)
end
end