handle undefined player.elements.buttons.play

This commit is contained in:
Michael DePetrillo 2018-06-25 12:00:02 +02:00
parent 86406ee59a
commit b6ddf144f4

View File

@ -431,9 +431,11 @@ class Listeners {
};
// Play/pause toggle
if (this.player.elements.buttons.play) {
Array.from(this.player.elements.buttons.play).forEach(button => {
bind(button, 'click', this.player.togglePlay, 'play');
});
}
// Pause
bind(this.player.elements.buttons.restart, 'click', this.player.restart, 'restart');