diff --git a/nip70/nip70.go b/nip70/nip70.go new file mode 100644 index 0000000..4cb0755 --- /dev/null +++ b/nip70/nip70.go @@ -0,0 +1,12 @@ +package nip70 + +import "github.com/nbd-wtf/go-nostr" + +func IsProtected(event *nostr.Event) bool { + for _, tag := range event.Tags { + if len(tag) == 1 && tag[0] == "-" { + return true + } + } + return false +}