Skip to content

Commit

Permalink
fix: wrong selection of default audio language
Browse files Browse the repository at this point in the history
it would always fallback to "en"
as the loop was over array keys not values
  • Loading branch information
bonswouar authored and Bnyro committed Jan 7, 2025
1 parent 62ceb1d commit b39574a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/VideoPlayer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ export default {
// Set the audio language
const prefLang = this.getPreferenceString("hl", "en").substr(0, 2);
var lang = "en";
for (var l in player.getAudioLanguages()) {
for (var l of player.getAudioLanguages()) {
if (l == prefLang) {
lang = l;
return;
Expand Down

0 comments on commit b39574a

Please sign in to comment.