Commit b55f22afc042f937e26a2e019b9b60f66d347b34

Authored by Dmitriy Zaporozhets
1 parent 959863b9

Correctly escape search query

Showing 1 changed file with 2 additions and 1 deletions   Show diff stats
app/contexts/search_context.rb
... ... @@ -6,7 +6,8 @@ class SearchContext
6 6 end
7 7  
8 8 def execute
9   - query = Shellwords.shellescape(params[:search])
  9 + query = params[:search]
  10 + query = Shellwords.shellescape(query) if query.present?
10 11  
11 12 return result unless query.present?
12 13  
... ...