Skip to content

Commit

Permalink
fix(iframeAPI): Fix setSubtitles command language param.
Browse files Browse the repository at this point in the history
setRequestingSubtitles requires the last parameter in certain format.
  • Loading branch information
damencho authored Feb 19, 2025
1 parent 93de398 commit 9ad42a9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/API/API.js
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,8 @@ function initCommands() {
APP.store.dispatch(toggleRequestingSubtitles());
},
'set-subtitles': (enabled, displaySubtitles, language) => {
APP.store.dispatch(setRequestingSubtitles(enabled, displaySubtitles, language));
APP.store.dispatch(setRequestingSubtitles(
enabled, displaySubtitles, language ? `translation-languages:${language}` : null));
},
'toggle-tile-view': () => {
sendAnalytics(createApiEvent('tile-view.toggled'));
Expand Down

0 comments on commit 9ad42a9

Please sign in to comment.