Skip to content

Commit

Permalink
Correctly escape search query
Browse files Browse the repository at this point in the history
  • Loading branch information
dzaporozhets authored and jacobvosmaer committed Nov 4, 2013
1 parent 8a5bf01 commit 6d8b0bb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/contexts/search_context.rb
Expand Up @@ -6,7 +6,8 @@ def initialize(project_ids, params)
end

def execute
query = Shellwords.shellescape(params[:search])
query = params[:search]
query = Shellwords.shellescape(query) if query.present?

return result unless query.present?

Expand Down

0 comments on commit 6d8b0bb

Please sign in to comment.