Skip to content

Commit c04c010

Browse files
Adrien Grsmtomderrick
authored andcommitted
props subscribing to media events now receive synthetic React event (#46)
1 parent 7e867df commit c04c010

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/components/video/Video.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,10 @@ var Video = React.createClass({
8181
// Set up all React media events and call method
8282
// on props if provided.
8383
this.mediaEventProps = EVENTS.reduce((p, c) => {
84-
p[c] = () => {
84+
p[c] = (e) => {
8585
if (c in this.props && typeof this.props[c] === 'function') {
8686
// A prop exists for this mediaEvent, call it.
87-
this.props[c]();
87+
this.props[c](e);
8888
}
8989
this._updateStateFromVideo();
9090
};

0 commit comments

Comments
 (0)