Add check for format.resolution in Invidious adaptive formats
This commit is contained in:
parent
fde06914b5
commit
6519b054c6
|
@ -546,7 +546,9 @@ export default Vue.extend({
|
||||||
this.recommendedVideos = result.recommendedVideos
|
this.recommendedVideos = result.recommendedVideos
|
||||||
this.adaptiveFormats = result.adaptiveFormats.map((format) => {
|
this.adaptiveFormats = result.adaptiveFormats.map((format) => {
|
||||||
format.bitrate = parseInt(format.bitrate)
|
format.bitrate = parseInt(format.bitrate)
|
||||||
|
if (typeof format.resolution !== 'undefined') {
|
||||||
format.height = parseInt(format.resolution.replace('p', ''))
|
format.height = parseInt(format.resolution.replace('p', ''))
|
||||||
|
}
|
||||||
return format
|
return format
|
||||||
})
|
})
|
||||||
this.isLive = result.liveNow
|
this.isLive = result.liveNow
|
||||||
|
|
Loading…
Reference in New Issue