diff --git a/multirepeater.go b/multirepeater.go index 0ca8127..66cea3b 100644 --- a/multirepeater.go +++ b/multirepeater.go @@ -20,7 +20,7 @@ func NewMultiRepeater[ID comparable]() *MultiRepeater[ID] { } // Works almost same as original StartRepeater, but delegates stop function managment to MultiRepeater and requires id for repeater. -// Returns `true` on success, and `false` if given id is occupied. +// Returns `true` on success, and `false` if passed id is occupied. func (mr *MultiRepeater[ID]) StartRepeater(id ID, frequency time.Duration, fnToCall func()) bool { mr.mux.Lock() if mr.repeaters[id] != nil { @@ -32,7 +32,7 @@ func (mr *MultiRepeater[ID]) StartRepeater(id ID, frequency time.Duration, fnToC return true } -// Stops repeater by ID. Return `true` on success, and `false` if given id is not found. +// Stops repeater by ID. Return `true` on success, and `false` if passed id is not found. func (mr *MultiRepeater[ID]) StopRepeater(id ID) bool { mr.mux.Lock() if mr.repeaters[id] == nil { diff --git a/repeater.go b/repeater.go index d0e6571..979ecf6 100644 --- a/repeater.go +++ b/repeater.go @@ -4,7 +4,7 @@ import ( "time" ) -// Start repeating fnToCall with given frequency, frequency can be 0, if so, ticker won't be used. +// Start repeating fnToCall with passed frequency, frequency can be 0, if so, ticker won't be used. // Use returned function to stop repeater, this function waits until repeater is stopped. func StartRepeater(frequency time.Duration, fnToCall func()) (stop func()) { if fnToCall == nil {