Compare commits

...

2 Commits

Author SHA1 Message Date
fiatjaf
9f99b9827a add notice about the new library. 2025-09-22 16:55:36 -03:00
clark
8d5fc324f7 fix(deleting): handle relay URLs with port numbers using SplitN 2025-09-22 16:40:15 -03:00
2 changed files with 9 additions and 1 deletions

View File

@@ -1,3 +1,11 @@
<div>
<p><b>This repository is in maintenance mode and adventurous programmers are encouraged to try <a href="https://pkg.go.dev/fiatjaf.com/nostr/khatru"><code>fiatjaf.com/nostr/khatru@master</code></a> instead.</b></p>
<p>The core codebase and functionality are the same, but the API breaks a little bit (for good reason) and there are some new features.</p>
</div>
---
# khatru, a relay framework [![docs badge](https://img.shields.io/badge/docs-reference-blue)](https://pkg.go.dev/github.com/fiatjaf/khatru#Relay)
[![Run Tests](https://github.com/fiatjaf/khatru/actions/workflows/test.yml/badge.svg)](https://github.com/fiatjaf/khatru/actions/workflows/test.yml)

View File

@@ -19,7 +19,7 @@ func (rl *Relay) handleDeleteRequest(ctx context.Context, evt *nostr.Event) erro
case "e":
f = nostr.Filter{IDs: []string{tag[1]}}
case "a":
spl := strings.Split(tag[1], ":")
spl := strings.SplitN(tag[1], ":", 3)
if len(spl) != 3 {
continue
}