From c4534c716026ad4a9abdbe998c02a98b54693bb3 Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Thu, 11 Jun 2026 18:42:14 -0300 Subject: [PATCH] nip5a: normalize http url. --- nip5a/nip5a.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nip5a/nip5a.go b/nip5a/nip5a.go index dd8b679..fa2328d 100644 --- a/nip5a/nip5a.go +++ b/nip5a/nip5a.go @@ -97,7 +97,9 @@ func (sm SiteManifest) ToEvent() nostr.Event { event.Tags = append(event.Tags, nostr.Tag{"path", NormalizePath(path), hex.EncodeToString(hash[:])}) } for _, s := range sm.Servers { - event.Tags = append(event.Tags, nostr.Tag{"server", s}) + if ns, err := nostr.NormalizeHTTPURL(s); err == nil { + event.Tags = append(event.Tags, nostr.Tag{"server", ns}) + } } if sm.Title != "" { event.Tags = append(event.Tags, nostr.Tag{"title", sm.Title})