Skip to content

Commit

Permalink
Remove public version const
Browse files Browse the repository at this point in the history
Inspired by #120 (comment).
  • Loading branch information
anacrolix committed May 10, 2023
1 parent 9ce7673 commit 669cd17
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
12 changes: 8 additions & 4 deletions dlna/dms/dms.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,19 @@ import (
"github.com/anacrolix/dms/transcode"
"github.com/anacrolix/dms/upnp"
"github.com/anacrolix/dms/upnpav"
"github.com/anacrolix/dms/version"
"github.com/anacrolix/ffprobe"
)

// This is used when communicating with other devices, such as over HTTP. I don't imagine we're
// popular enough to have special treatment yet. This value would change if we made potentially
// breaking changes to our behaviour that other devices might want to act on.
const serverVersion = "1"

var (
serverField = fmt.Sprintf(`Linux/3.4 DLNADOC/1.50 UPnP/1.0 %s/%s`,
userAgentProduct,
version.DmsVersion)
rootDeviceModelName = fmt.Sprintf("%s %s", userAgentProduct, version.DmsVersion)
serverVersion)
rootDeviceModelName = fmt.Sprintf("%s %s", userAgentProduct, serverVersion)
)

const (
Expand Down Expand Up @@ -443,7 +447,7 @@ func (me *Server) serveDLNATranscode(w http.ResponseWriter, r *http.Request, pat
} else {
logTsName = tsname
}
stderrPath:= strings.Replace(me.TranscodeLogPattern, "[tsname]", logTsName, -1)
stderrPath := strings.Replace(me.TranscodeLogPattern, "[tsname]", logTsName, -1)
var logFile io.Writer
if stderrPath != "" {
os.MkdirAll(filepath.Dir(stderrPath), 0o750)
Expand Down
3 changes: 0 additions & 3 deletions version/version.go

This file was deleted.

0 comments on commit 669cd17

Please sign in to comment.