Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
gusin13 committed Jan 3, 2025
1 parent cd43bc9 commit 2f6429e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions internal/services/delegation.go
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,11 @@ func (s *Service) processBTCDelegationUnbondedEarlyEvent(
if !shouldProcess {
// Event is valid but should be skipped
if shouldEmitEvent {
log.Debug().
Str("staking_tx", unbondedEarlyEvent.StakingTxHash).
Str("event_type", EventBTCDelgationUnbondedEarly.String()).
Msg("skip processing but emit unbonding event")

delegation, dbErr := s.db.GetBTCDelegationByStakingTxHash(ctx, unbondedEarlyEvent.StakingTxHash)
if dbErr != nil {
return types.NewError(
Expand Down Expand Up @@ -394,6 +399,11 @@ func (s *Service) processBTCDelegationExpiredEvent(
if !shouldProcess {
// Event is valid but should be skipped
if shouldEmitEvent {
log.Debug().
Str("staking_tx", expiredEvent.StakingTxHash).
Str("event_type", EventBTCDelegationExpired.String()).
Msg("skip processing but emit unbonding event")

delegation, dbErr := s.db.GetBTCDelegationByStakingTxHash(ctx, expiredEvent.StakingTxHash)
if dbErr != nil {
return types.NewError(
Expand Down

0 comments on commit 2f6429e

Please sign in to comment.