Skip to content

Commit

Permalink
trim currency search
Browse files Browse the repository at this point in the history
  • Loading branch information
gadhiyamanan committed Sep 18, 2023
1 parent 01c5b71 commit 29bd32a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/iou/IOUCurrencySelection.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ function IOUCurrencySelection(props) {
};
});

const searchRegex = new RegExp(Str.escapeForRegExp(searchValue), 'i');
const searchRegex = new RegExp(Str.escapeForRegExp(searchValue.trim()), 'i');
const filteredCurrencies = _.filter(currencyOptions, (currencyOption) => searchRegex.test(currencyOption.text));
const isEmpty = searchValue.trim() && !filteredCurrencies.length;

Expand Down

0 comments on commit 29bd32a

Please sign in to comment.