From 859a6fb938bb9ee2a317c46dfa4fcc1af49608f0 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Thu, 18 Feb 2021 10:34:06 +0000 Subject: Add latest changes from gitlab-org/gitlab@13-9-stable-ee --- app/assets/javascripts/search/highlight_blob_search_result.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/assets/javascripts/search/highlight_blob_search_result.js') diff --git a/app/assets/javascripts/search/highlight_blob_search_result.js b/app/assets/javascripts/search/highlight_blob_search_result.js index 3c3ac3582d0..c553d5b14a0 100644 --- a/app/assets/javascripts/search/highlight_blob_search_result.js +++ b/app/assets/javascripts/search/highlight_blob_search_result.js @@ -1,7 +1,7 @@ -export default () => { +export default (search = '') => { const highlightLineClass = 'hll'; const contentBody = document.getElementById('content-body'); - const searchTerm = contentBody.querySelector('.js-search-input').value.toLowerCase(); + const searchTerm = search.toLowerCase(); const blobs = contentBody.querySelectorAll('.blob-result'); blobs.forEach((blob) => { -- cgit v1.2.1