about summary refs log tree commit diff stats
path: root/src/utils
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2022-12-05 18:09:46 +0100
committerbptato <nincsnevem662@gmail.com>2022-12-05 18:09:46 +0100
commitc392ff7ed6499e00376737d4f2ffccccdee27c76 (patch)
tree773b78d1fe2cdf9a41e663b6cff5b23b99ccbbe6 /src/utils
parent0c8052ca56192c5c7891e19f975856e475656c1e (diff)
downloadchawan-c392ff7ed6499e00376737d4f2ffccccdee27c76.tar.gz
Fix a punycode decoding bug
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/twtstr.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim
index 0bce4591..53d68798 100644
--- a/src/utils/twtstr.nim
+++ b/src/utils/twtstr.nim
@@ -528,7 +528,7 @@ func processIdna(str: string, checkhyphens, checkbidi, checkjoiners, transitiona
     var s = label
     if label.startsWith("xn--"):
       try:
-        s = punycode.decode(label)
+        s = punycode.decode(label.substr("xn--".len))
       except PunyError:
         return none(string) #error
     #TODO check normalization