diff --git a/client.go b/client.go index 2daa00a..32273a0 100644 --- a/client.go +++ b/client.go @@ -7,56 +7,59 @@ import ( // "fmt" ) +var directoryMap map[string][]int = make(map[string][]int) + func togglePlayBack(connection mpd.Client) error { status, err := connection.Status() - if(status["state"] == "play" && err == nil){ + if status["state"] == "play" && err == nil { connection.Pause(true) - } else if(status["state"] == "pause" && err == nil) { + } else if status["state"] == "pause" && err == nil { connection.Play(-1) } return err } -func join ( stringSlice [] string ) string{ +func join(stringSlice []string) string { var _s string = stringSlice[0] - for i:= 1; i