Skip to content

Commit 962d2e6

Browse files
author
KoalaSat
authored
Merge pull request #2131 from aftermath2/external_pix_orders_icon
Ignore case differences during payment methods icon matching
2 parents cc5239b + 262891c commit 962d2e6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

frontend/src/components/PaymentMethods/StringAsIcons.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ const StringAsIcons: React.FC<StringAsIconsProps> = ({
3333

3434
// Adds icons for each PaymentMethod that matches
3535
methods.forEach((method, i) => {
36-
const regex = new RegExp(`\\b${method.name}\\b`, 'g');
36+
const regex = new RegExp(`\\b${method.name.toLowerCase()}\\b`, 'g');
3737

38-
if (regex.test(customMethods)) {
38+
if (regex.test(customMethods.toLowerCase())) {
3939
customMethods = customMethods.replace(regex, '');
4040
rows.push(
4141
<Tooltip

0 commit comments

Comments
 (0)