bbc / react-transcript-editor

A React component to make correcting automated transcriptions of audio and video easier and faster. By BBC News Labs. - Work in progress

Home Page:https://bbc.github.io/react-transcript-editor

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MediaPlayer Cannot read property 'duration' of null - Storybook error

pietrop opened this issue · comments

Describe the bug

as noticed by @emettely when going to MediaPlayer in storybook get error Cannot read property 'duration' of null

To Reproduce
Steps to reproduce the behavior:

  1. Go to demo app MediaPlayer https://bbc.github.io/react-transcript-editor/?path=/story/mediaplayer--default
  2. See error Cannot read property 'duration' of null - see screenshot below

Expected behavior

Not see an error when looking at MediaPlayer in storybook

Screenshots

in current master

Screenshot 2019-10-02 at 18 22 57

Additional context

Likely to be just to do with initialisation of MediaPlayer component in storybook.

Via @emettely

Original that worked: 9557faa0f66c4abb711301e2fc94fdcd5f48dc4c
Change that introduced bug to story: 45c324dc1dcd2fdd3ca94b1e14a699eab11587e0
so it’s between those two hashes some changes have been introduced