Commit 5c723f4d by aquilescanta Committed by Oliver Woodman

Prevent text tracks with no language being selected by default

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=154421706
parent 7761cdcd
......@@ -867,7 +867,8 @@ public class DefaultTrackSelector extends MappingTrackSelector {
}
protected static boolean formatHasLanguage(Format format, String language) {
return TextUtils.equals(language, Util.normalizeLanguageCode(format.language));
return language != null
&& TextUtils.equals(language, Util.normalizeLanguageCode(format.language));
}
// Viewport size util methods.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment