Prevent text tracks with no language being selected by default
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=154421706
This commit is contained in:
parent
7761cdcd1e
commit
5c723f4d3d
@ -867,7 +867,8 @@ public class DefaultTrackSelector extends MappingTrackSelector {
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected static boolean formatHasLanguage(Format format, String language) {
|
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.
|
// Viewport size util methods.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user