Skip to content

Commit

Permalink
feat: add notification info
Browse files Browse the repository at this point in the history
  • Loading branch information
Satont committed May 12, 2024
1 parent af3af9b commit 60fc034
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ type SubHandler struct {
// Returns whether the subscription should be accepted.
VerifyChallenge func(h *esb.ResponseHeaders, chal *esb.SubscriptionChallenge) bool
OnRevocate func(h *esb.ResponseHeaders, revocation *esb.RevocationNotification)
OnNotification func(h *esb.ResponseHeaders)
OnNotification func(h *esb.ResponseHeaders, notification *esb.EventNotification)

// IDTracker used to deduplicate notifications
IDTracker IDTracker
Expand Down Expand Up @@ -294,7 +294,7 @@ func (s *SubHandler) handleNotification(
}
event := notification.Event
if s.OnNotification != nil {
s.OnNotification(h)
s.OnNotification(h, &notification)
}

switch h.SubscriptionType {
Expand Down

0 comments on commit 60fc034

Please sign in to comment.