fix(video-quality-dialog): Initial value.
Fixes an issue when the video quality dialog is opened for first time and config.videoQuality.persist is true there isn't any selected option.
This commit is contained in:
parent
a270e4300a
commit
1740aaf973
|
@ -45,11 +45,10 @@ MiddlewareRegistry.register(({ dispatch, getState }) => next => action => {
|
|||
case SET_CONFIG: {
|
||||
const state = getState();
|
||||
const { videoQuality = {} } = state['features/base/config'];
|
||||
const { persistedPrefferedVideoQuality } = state['features/video-quality-persistent-storage'];
|
||||
|
||||
if (videoQuality.persist) {
|
||||
dispatch(
|
||||
setPreferredVideoQuality(
|
||||
state['features/video-quality-persistent-storage'].persistedPrefferedVideoQuality));
|
||||
if (videoQuality.persist && typeof persistedPrefferedVideoQuality !== 'undefined') {
|
||||
dispatch(setPreferredVideoQuality(persistedPrefferedVideoQuality));
|
||||
}
|
||||
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue