Commit 7fd3eb00 by zhanghaozhe

video record

parent 16488323
......@@ -104,7 +104,9 @@ class Video extends Component {
setupRecord = () => {
this.recordSocket = io(API.record)
this.recordSocket = io(API.record,{
transports: ['websocket']
})
this.recordSocket.on('seek', time => {
this.player.currentTime(time)
})
......@@ -115,7 +117,7 @@ class Video extends Component {
}
sendRecord = () => {
if (this.recordSocket) {
if (this.recordSocket && this.player) {
this.recordSocket.emit('addRecord', this.recordUserInfo())
}
}
......
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