Added a check for 'blank', so search is not triggered on empty string or spaces