1
0
mirror of https://github.com/uetchy/namae.git synced 2025-03-17 04:30:31 +09:00

fix: not to match exact tld

This commit is contained in:
uetchy 2020-02-08 21:00:53 +09:00
parent 3e6c678c46
commit 8730effb71

View File

@ -10,7 +10,7 @@ const DomainCard: React.FC<{query: string}> = ({query}) => {
const lowerCase = query.toLowerCase();
const domainHackSuggestions = zones
.map((zone) => new RegExp(`${zone}$`).exec(lowerCase))
.map((zone) => new RegExp(`(?<=.)${zone}$`).exec(lowerCase))
.filter((s): s is RegExpExecArray => s !== null)
.map(
(m) =>