Commit 4d1445e2 authored by anton's avatar anton
Browse files

Fix exception when media has no duration

parent 44488585
......@@ -70,8 +70,8 @@
},
duration () {
if (this.annotation && this.annotation.target.selector) {
console.log(this.annotation.target.selector)
return this.annotation.target.selector.getDuration().toFormat(constants.config.TIMECODE_FORMAT_DURATION)
const duration = this.annotation.target.selector.getDuration()
if (duration) return duration.toFormat(constants.config.TIMECODE_FORMAT_DURATION)
}
}
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment