diff --git a/shell.go b/shell.go index 0c803a66e..9b122a0a7 100644 --- a/shell.go +++ b/shell.go @@ -389,6 +389,7 @@ func (s *Shell) FindProvs(ctx context.Context, cid string) (<-chan pstore.PeerIn outchan := make(chan pstore.PeerInfo, 4) go func() { + defer close(outchan) defer cancel() var n notif.QueryEvent