diff options
author | Michael Kozono <mkozono@gmail.com> | 2017-08-07 16:41:39 -0700 |
---|---|---|
committer | Michael Kozono <mkozono@gmail.com> | 2017-08-08 10:30:07 -0700 |
commit | fccd64bb6ae0b06252cf667492ca5e5a0753c4f4 (patch) | |
tree | b3b1072b9c6a4f07793165850b1af650f08e54d2 /app | |
parent | cfabe7bf38f175b28c8c0a1bec584b6b751cbba5 (diff) | |
download | gitlab-ce-fccd64bb6ae0b06252cf667492ca5e5a0753c4f4.tar.gz |
Fix conflicting redirect search
Diffstat (limited to 'app')
-rw-r--r-- | app/models/redirect_route.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/redirect_route.rb b/app/models/redirect_route.rb index 964175ddab8..a034aacb23c 100644 --- a/app/models/redirect_route.rb +++ b/app/models/redirect_route.rb @@ -8,5 +8,5 @@ class RedirectRoute < ActiveRecord::Base presence: true, uniqueness: { case_sensitive: false } - scope :matching_path_and_descendants, -> (path) { where('redirect_routes.path = ? OR redirect_routes.path LIKE ?', path, "#{sanitize_sql_like(path)}/%") } + scope :matching_path_and_descendants, -> (path) { where('LOWER(redirect_routes.path) = LOWER(?) OR LOWER(redirect_routes.path) LIKE LOWER(?)', path, "#{sanitize_sql_like(path)}/%") } end |