Skip to content

Commit 3a93bbd

Browse files
pass down tagged pubkeys from job request
1 parent 773fa67 commit 3a93bbd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

nostr/nip90.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ type Nip90Input struct {
7373
JobRequestEventJSON string
7474
Event *goNostr.Event
7575
ResultKind int
76+
TaggedPubkeys map[string]struct{}
7677
}
7778

7879
func Nip90InputFromJobRequestEvent(e *goNostr.Event) (*Nip90Input, error) {
@@ -83,6 +84,7 @@ func Nip90InputFromJobRequestEvent(e *goNostr.Event) (*Nip90Input, error) {
8384
Event: e,
8485
ResultKind: responseKind(e.Kind),
8586
Inputs: make([]*Input, 0, 1),
87+
TaggedPubkeys: make(map[string]struct{}),
8688
}
8789

8890
eventJson, err := json.Marshal(e)
@@ -121,6 +123,8 @@ func Nip90InputFromJobRequestEvent(e *goNostr.Event) (*Nip90Input, error) {
121123
return nil, err
122124
}
123125
input.BidMillisats = bidMillisats
126+
} else if e.Tags[i][0] == "p" && len(e.Tags[i]) == 2 {
127+
input.TaggedPubkeys[e.Tags[i][0]] = struct{}{}
124128
}
125129
}
126130
}

0 commit comments

Comments
 (0)