update with new props

auto_join_3.3
Mészáros Mihály 2020-04-22 12:56:30 +02:00
parent 3236a18a0b
commit d07b2a2101
1 changed files with 3 additions and 2 deletions

View File

@ -34,9 +34,10 @@ export default class PeerAudio extends React.PureComponent
// eslint-disable-next-line camelcase // eslint-disable-next-line camelcase
UNSAFE_componentWillReceiveProps(nextProps) UNSAFE_componentWillReceiveProps(nextProps)
{ {
const { audioTrack } = nextProps; const { audioTrack, audioOutputDevice } = nextProps;
this._setTrack(audioTrack); this._setTrack(audioTrack);
this._setOutputDevice(audioOutputDevice);
} }
_setTrack(audioTrack) _setTrack(audioTrack)