Rename GetFFmpegVersion
to GetVersion
in FFmpegContract
for consistency and clarity.
This commit is contained in:
parent
c8619cdc7f
commit
a9c59137af
@ -18,7 +18,7 @@ type ProgressContract interface {
|
||||
|
||||
type FFmpegContract interface {
|
||||
GetPath() string
|
||||
GetFFmpegVersion() (string, error)
|
||||
GetVersion() (string, error)
|
||||
GetEncoders(scanner func(scanner *bufio.Reader)) error
|
||||
RunConvert(setting ConvertSetting, progress ProgressContract, beforeWait func(cmd *exec.Cmd), afterWait func(cmd *exec.Cmd)) error
|
||||
}
|
||||
@ -49,7 +49,7 @@ func (f *ffmpeg) GetPath() string {
|
||||
return f.path
|
||||
}
|
||||
|
||||
func (f *ffmpeg) GetFFmpegVersion() (string, error) {
|
||||
func (f *ffmpeg) GetVersion() (string, error) {
|
||||
cmd := exec.Command(f.path, "-version")
|
||||
utils.PrepareBackgroundCommand(cmd)
|
||||
out, err := cmd.CombinedOutput()
|
||||
|
@ -89,7 +89,7 @@ func (u *utilities) GetFFmpegVersion() string {
|
||||
return lang.L("errorFFmpegVersion")
|
||||
}
|
||||
|
||||
version, err := ffmpegService.GetFFmpegVersion()
|
||||
version, err := ffmpegService.GetVersion()
|
||||
if err != nil {
|
||||
return lang.L("errorFFmpegVersion")
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user