« get me outta code hell

mtui - Music Text User Interface - user-friendly command line music player
about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--backend.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/backend.js b/backend.js
index ffa620a..d7d7678 100644
--- a/backend.js
+++ b/backend.js
@@ -791,7 +791,7 @@ export default class Backend extends EventEmitter {
     queuePlayer.on('playing', track => {
       if (track) {
         const metadata = this.getMetadataFor(track)
-        queuePlayer.setDuration(metadata.duration)
+        queuePlayer.setDuration(metadata?.duration)
       }
     })