aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/main.go b/main.go
index 10be005..dcde8a3 100644
--- a/main.go
+++ b/main.go
@@ -201,7 +201,6 @@ func formatOutput(p *player, icon string, fstr string, maxTitleLen int) string {
case tokPosition:
var position string
if p.Length > 0 {
- p.GetPosition()
position = secondsToString(int(p.Position / 1000000))
} else {
position = secondsToString(0)
@@ -646,6 +645,7 @@ func main() {
time.Sleep(POLL * time.Millisecond)
if len(players.mpris2.List) != 0 {
if players.mpris2.List[players.mpris2.Current].Playing {
+ players.mpris2.List[players.mpris2.Current].GetPosition()
go fmt.Fprintln(writer, players.JSON())
}
}