blossom/nsite tweaks.

This commit is contained in:
fiatjaf
2026-04-22 15:51:00 -03:00
parent 078ee94465
commit 223d95461f
3 changed files with 253 additions and 15 deletions
+7 -3
View File
@@ -72,12 +72,16 @@ func ParseSiteManifest(event *nostr.Event) (*SiteManifest, error) {
}
}
if len(sm.Paths) == 0 {
return sm, fmt.Errorf("nsite has zero paths listed")
}
return sm, nil
}
func (sm *SiteManifest) ToEvent(pubkey nostr.PubKey) *nostr.Event {
event := &nostr.Event{
PubKey: pubkey,
func (sm SiteManifest) ToEvent() nostr.Event {
event := nostr.Event{
PubKey: sm.Pubkey,
CreatedAt: nostr.Now(),
Tags: nostr.Tags{},
}