Skip to content

Commit

Permalink
Update assets/vidstack_helper.js
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
skerbis and coderabbitai[bot] authored Sep 27, 2024
1 parent 7e04973 commit 3fc072c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assets/vidstack_helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ document.addEventListener('DOMContentLoaded', function() {
const videoLayouts = document.querySelectorAll('media-video-layout');
videoLayouts.forEach(layout => {
const player = layout.closest('media-player');
const lang = player ? (player.getAttribute('lang') || 'en') : 'en';
const lang = player?.getAttribute('lang') || 'en';
layout.translations = translations[lang] || translations['en'];
});

Expand Down

0 comments on commit 3fc072c

Please sign in to comment.