Use named helper instead of hardcoded route
This commit is contained in:
parent
3129aeb133
commit
eae9c14168
1 changed files with 1 additions and 1 deletions
|
|
@ -18,7 +18,7 @@ class PeopleController < ApplicationController
|
|||
params[:q] ||= params[:term] || ''
|
||||
|
||||
if (params[:q][0] == 35 || params[:q][0] == '#') && params[:q].length > 1
|
||||
redirect_to "/tags/#{params[:q].gsub("#", "")}"
|
||||
redirect_to tag_path(:name => params[:q].gsub("#", ""))
|
||||
return
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue