Files
gortsplib/pkg/base/path.go
2024-09-15 22:51:55 +02:00

18 lines
310 B
Go

package base
import (
"strings"
)
// PathSplitQuery splits a path from a query.
//
// Deprecated: not useful anymore.
func PathSplitQuery(pathAndQuery string) (string, string) {
i := strings.Index(pathAndQuery, "?")
if i >= 0 {
return pathAndQuery[:i], pathAndQuery[i+1:]
}
return pathAndQuery, ""
}