revert drive-by refactoring

This commit is contained in:
Alain Brenzikofer
2026-09-10 11:25:28 +02:00
parent 5da77572c9
commit f171ff2fbf
+6 -2
View File
@@ -153,8 +153,12 @@ instance Encoding SimplexTLD where
_ -> fail "bad SimplexTLD"
fullDomainName :: SimplexDomain -> Text
fullDomainName SimplexDomain {nameTLD, domain, subDomain} =
T.intercalate "." (reverse subDomain ++ [domain]) <> tldSuffix nameTLD
fullDomainName SimplexDomain {nameTLD, domain, subDomain} = T.intercalate "." (reverse subDomain ++ [domain] ++ tld')
where
tld' = case nameTLD of
TLDSimplex -> ["simplex"]
TLDTesting -> ["testing"]
TLDWeb -> []
-- | A web name carries its own TLD, so it gets no suffix.
tldSuffix :: SimplexTLD -> Text