forked from hrfee/waybar-mpris
change order of writers in io.Multiwriter
io.MultiWriter (i think) thinks dataWrite.Write fails, and so doesn't continue writing to all other outputs. This just makes it the last one, should fix #4.
This commit is contained in:
4
main.go
4
main.go
@@ -484,9 +484,9 @@ func listenForCommands(players *players) {
|
||||
players,
|
||||
}
|
||||
if isSharing {
|
||||
WRITER = io.MultiWriter(SHAREWRITER, DATAWRITER, os.Stdout)
|
||||
WRITER = io.MultiWriter(os.Stdout, SHAREWRITER, DATAWRITER)
|
||||
} else {
|
||||
WRITER = io.MultiWriter(DATAWRITER, os.Stdout)
|
||||
WRITER = io.MultiWriter(os.Stdout, DATAWRITER)
|
||||
}
|
||||
isDataSharing = true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user