Skip to content

Commit

Permalink
fix: join locales directly
Browse files Browse the repository at this point in the history
  • Loading branch information
nobkd committed Mar 26, 2023
1 parent 8053e5c commit 123a5f0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions background.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ const patterns = [
'https://*/maps?*output=embed*'
];

const gLocales = ['com', 'de']; // TODO: collect more locales
const gLocales = ['com', 'de'].join('|'); // TODO: collect more locales
const matcher = new RegExp(
`^(https?:\/\/)?(maps\.google\.(${gLocales.join('|')})\/maps\?.*output=embed|(www\.)?google\.(${gLocales.join('|')})\/maps\/embed\?)`
`^(https?:\/\/)?(maps\.google\.(${gLocales})\/maps\?.*output=embed|(www\.)?google\.(${gLocales})\/maps\/embed\?)`
);


Expand Down

0 comments on commit 123a5f0

Please sign in to comment.