Skip to content

Commit

Permalink
fix play file issue
Browse files Browse the repository at this point in the history
  • Loading branch information
TimothyYe committed Sep 5, 2019
1 parent bebb28f commit 55d6d49
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dict_result.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ func SaveVoiceFile(name string, body io.ReadCloser) (string, error) {
func DoPlayFile(aFile string) error {

cmd := exec.Command("mpg123", aFile)
if _, err := exec.LookPath("mpv"); nil != err {
if _, err := exec.LookPath("mpv"); err == nil {
// andoird termux only have mpv
cmd = exec.Command("mpv", aFile)
//log.Println("mpv ", aFile)
Expand Down

0 comments on commit 55d6d49

Please sign in to comment.