Skip to content
This repository was archived by the owner on Jan 24, 2025. It is now read-only.

Commit c5edd2a

Browse files
committed
Fix some comments.
1 parent 874e1ef commit c5edd2a

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

pkg/protocol/engine/mempool/v1/inclusion_flags.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,24 +75,24 @@ func (s *inclusionFlags) OnRejected(callback func()) {
7575
s.rejected.OnTrigger(callback)
7676
}
7777

78-
// IsCommitted returns true if the entity was committed.
78+
// CommittedSlot returns the slot in which the entity is committed and a bool value indicating if the entity was committed.
7979
func (s *inclusionFlags) CommittedSlot() (slot iotago.SlotIndex, isCommitted bool) {
8080
return s.committedSlot.Get(), s.committedSlot.Get() != 0
8181
}
8282

83-
// OnCommitted registers a callback that gets triggered when the entity gets committed.
83+
// OnCommittedSlotUpdated registers a callback that gets triggered when the slot in which the entity is committed gets updated..
8484
func (s *inclusionFlags) OnCommittedSlotUpdated(callback func(slot iotago.SlotIndex)) {
8585
s.committedSlot.OnUpdate(func(_ iotago.SlotIndex, newValue iotago.SlotIndex) {
8686
callback(newValue)
8787
})
8888
}
8989

90-
// IsOrphaned returns true if the entity was orphaned.
90+
// OrphanedSlot returns a slot in which the entity has been orphaned and a bool flag indicating whether it was orphaned.
9191
func (s *inclusionFlags) OrphanedSlot() (slot iotago.SlotIndex, isOrphaned bool) {
9292
return s.orphanedSlot.Get(), s.orphanedSlot.Get() != 0
9393
}
9494

95-
// OnOrphaned registers a callback that gets triggered when the entity gets orphaned.
95+
// OnOrphanedSlotUpdated registers a callback that gets triggered when the orphaned slot is updated.
9696
func (s *inclusionFlags) OnOrphanedSlotUpdated(callback func(slot iotago.SlotIndex)) {
9797
s.orphanedSlot.OnUpdate(func(_ iotago.SlotIndex, newValue iotago.SlotIndex) {
9898
callback(newValue)

pkg/protocol/sybilprotection/seatmanager/seatmanager.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,10 @@ type SeatManager interface {
3131
// OnlineCommittee returns the set of online validators that is used to track acceptance.
3232
OnlineCommittee() ds.Set[account.SeatIndex]
3333

34-
// SeatCount returns the number of seats in the SeatManager.
34+
// SeatCountInSlot returns the number of seats in the SeatManager for the given slot's epoch.
3535
SeatCountInSlot(slot iotago.SlotIndex) int
3636

37+
// SeatCountInEpoch returns the number of seats in the SeatManager for the given epoch.
3738
SeatCountInEpoch(epoch iotago.EpochIndex) int
3839

3940
// Interface embeds the required methods of the module.Interface.

0 commit comments

Comments
 (0)