Skip to content

Commit 48d58e1

Browse files
committed
added some comments
1 parent dfc697b commit 48d58e1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

janitor.go

+2
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,12 @@ func newJanitor(ctx context.Context, interval time.Duration) *janitor {
2323
return j
2424
}
2525

26+
// stop to stop the janitor.
2627
func (j *janitor) stop() {
2728
j.once.Do(func() { close(j.done) })
2829
}
2930

31+
// run with the given cleanup callback function.
3032
func (j *janitor) run(cleanup func()) {
3133
go func() {
3234
ticker := time.NewTicker(j.interval)

0 commit comments

Comments
 (0)