Code refactoring

This commit is contained in:
Alexey Khit
2023-08-18 15:51:28 +03:00
parent 063a192699
commit 76a00031cd
5 changed files with 24 additions and 17 deletions
-3
View File
@@ -6,8 +6,6 @@ import (
"strconv"
"strings"
"time"
"github.com/rs/zerolog/log"
)
const (
@@ -77,7 +75,6 @@ func Assert(ok bool) {
}
func Caller() string {
log.Error().Caller(0).Send()
_, file, line, _ := runtime.Caller(1)
return file + ":" + strconv.Itoa(line)
}
+7
View File
@@ -10,6 +10,13 @@ import (
"github.com/pion/rtp"
)
type Packet struct {
PayloadType uint8
Sequence uint16
Timestamp uint32
Payload []byte
}
var ErrCantGetTrack = errors.New("can't get track")
type Receiver struct {