From 3a2f681c9bbf2741172434146af56f99970e7996 Mon Sep 17 00:00:00 2001 From: Ardis Lu Date: Thu, 25 May 2023 21:56:06 -0700 Subject: [PATCH] Lowercase all names per UTS46 The normalization is not fully compliant but still works for most names --- index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.html b/index.html index 800dfa6..0119ac2 100644 --- a/index.html +++ b/index.html @@ -327,7 +327,7 @@ const formData = new FormData(event.target); const combined = `${formData.get('text')}\n${await formData.get('file').text()}`; // Concatenate textarea and file inputs - const parsed = new Set(combined.split('\n').map(c => c.split(',')).flat().map(e => e.trim())); // Split on newline or comma, flatten, trim whitespace, de-duplicate + const parsed = new Set(combined.split('\n').map(c => c.split(',')).flat().map(e => e.trim().toLocaleLowerCase())); // Split on newline or comma, flatten, trim whitespace, lowercase, and de-duplicate const cleaned = [...parsed].filter(name => name.slice(-4) === '.eth'); // Remove anything that does not end in '.eth' if (cleaned.length === 0) { -- 2.47.3