diff options
author | Florrie <towerofnix@gmail.com> | 2020-05-06 20:22:14 -0300 |
---|---|---|
committer | Florrie <towerofnix@gmail.com> | 2020-05-06 20:22:14 -0300 |
commit | a58f06407291824be882d896df58bace5e663196 (patch) | |
tree | 820b960aeef0ffa35dc02af7d16985f69ddeee08 | |
parent | 96075b8069133780ddeb9cdfde06496ab47b3ef2 (diff) |
clear timeData when a new track starts
this makes it so that the value of timeData at any point will always be associated with the track which is currently playing. i thought this was already how timeData worked -- that assumption is what makes a lot of the math in updateQueueLengthLabel work!
-rw-r--r-- | backend.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/backend.js b/backend.js index 900a822..69aa815 100644 --- a/backend.js +++ b/backend.js @@ -412,6 +412,7 @@ class QueuePlayer extends EventEmitter { return } + this.timeData = null this.playingTrack = item this.emit('playing', this.playingTrack, oldTrack, this) |