Skip to content

Commit b56876c

Browse files
committed
Make minimalPLIInterval local
Signed-off-by: Šimon Brandner <[email protected]>
1 parent 3f8dc77 commit b56876c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/peer/peer.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ var (
2424
ErrCantSubscribeToTrack = errors.New("can't subscribe to track")
2525
)
2626

27-
const minimalPLIInterval = time.Millisecond * 500
28-
2927
// A wrapped representation of the peer connection (single peer in the call).
3028
// The peer gets information about the things happening outside via public methods
3129
// and informs the outside world about the things happening inside the peer by posting
@@ -120,6 +118,8 @@ func (p *Peer[ID]) SubscribeTo(track *webrtc.TrackLocalStaticRTP) error {
120118
}
121119

122120
func (p *Peer[ID]) WriteRTCP(packets []rtcp.Packet, streamID string, trackID string, lastPLITimestamp int64) {
121+
const minimalPLIInterval = time.Millisecond * 500
122+
123123
packetsToSend := []rtcp.Packet{}
124124
var mediaSSRC uint32
125125
for _, receiver := range p.peerConnection.GetReceivers() {

0 commit comments

Comments
 (0)