Ensure search val is defined.

This commit is contained in:
Bryce Johnson 2016-10-25 12:46:28 +02:00
parent 995d4df151
commit f1bb7ddfa7
1 changed files with 1 additions and 1 deletions

View File

@ -54,7 +54,7 @@
},
maybeFocusOnSearch: function() {
const currentSearchVal = Issuable.searchState.current;
if (currentSearchVal !== '') {
if (currentSearchVal && currentSearchVal !== '') {
const queryLength = currentSearchVal.length;
const $searchInput = Issuable.searchState.elem;