diff --git a/event/custodial_registration.go b/event/custodial_registration.go index 68f3ca7..ee43e4d 100644 --- a/event/custodial_registration.go +++ b/event/custodial_registration.go @@ -23,6 +23,7 @@ func asCustodialRegistrationEvent(gev *geEvent.Event) (*eventCustodialRegistrati if !ok { return nil, false } + logg.Debug("parsed ev", "pl", pl, "ev", ev) return &ev, true } diff --git a/event/nats/nats.go b/event/nats/nats.go index a79e57b..cfbe378 100644 --- a/event/nats/nats.go +++ b/event/nats/nats.go @@ -19,7 +19,7 @@ var ( ) type NatsSubscription struct { - *event.Router + event.Router ctx context.Context conn *nats.Conn js jetstream.JetStream diff --git a/event/route.go b/event/route.go index 068244d..5d0bf0a 100644 --- a/event/route.go +++ b/event/route.go @@ -23,7 +23,7 @@ type Router struct { func(r *Router) Route(gev *geEvent.Event) error { logg.Debug("have event", "ev", gev) evCC, ok := asCustodialRegistrationEvent(gev) - if !ok { + if ok { return handleCustodialRegistration(evCC) } return fmt.Errorf("unexpected message")