Skip to content

Commit

Permalink
Expand comment
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoPolo committed Mar 27, 2024
1 parent b6caabb commit ff645ac
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions util.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ func SplitFunc(m Multiaddr, cb func(Component) bool) (Multiaddr, Multiaddr) {
// ForEach walks over the multiaddr, component by component.
//
// This function iterates over components *by value* to avoid allocating.
// Return true to continue iteration, false to stop.
func ForEach(m Multiaddr, cb func(c Component) bool) {
// Shortcut if we already have a component
if c, ok := m.(*Component); ok {
Expand Down

0 comments on commit ff645ac

Please sign in to comment.