refactor(tracker): rename trySend to TrySend to make it public

This commit is contained in:
5684185+vsariola@users.noreply.github.com
2025-04-30 22:00:34 +03:00
parent 0199658025
commit 9f89c37956
9 changed files with 36 additions and 36 deletions

View File

@ -85,10 +85,10 @@ func (b *Broker) PutAudioBuffer(buf *sointu.AudioBuffer) {
b.bufferPool.Put(buf)
}
// trySend is a helper function to send a value to a channel if it is not full.
// TrySend is a helper function to send a value to a channel if it is not full.
// It is guaranteed to be non-blocking. Return true if the value was sent, false
// otherwise.
func trySend[T any](c chan<- T, v T) bool {
func TrySend[T any](c chan<- T, v T) bool {
select {
case c <- v:
default: