Merge pull request #502 from feross/add-mpg
Add .mpg video extension to supported list
This commit is contained in:
@@ -17,25 +17,26 @@ function isPlayable (file) {
|
|||||||
function isVideo (file) {
|
function isVideo (file) {
|
||||||
var ext = path.extname(file.name).toLowerCase()
|
var ext = path.extname(file.name).toLowerCase()
|
||||||
return [
|
return [
|
||||||
'.mp4',
|
|
||||||
'.m4v',
|
|
||||||
'.webm',
|
|
||||||
'.mov',
|
|
||||||
'.mkv',
|
|
||||||
'.avi',
|
'.avi',
|
||||||
'.ogv'
|
'.m4v',
|
||||||
].indexOf(ext) > -1
|
'.mkv',
|
||||||
|
'.mov',
|
||||||
|
'.mp4',
|
||||||
|
'.mpg',
|
||||||
|
'.ogv',
|
||||||
|
'.webm'
|
||||||
|
].includes(ext)
|
||||||
}
|
}
|
||||||
|
|
||||||
function isAudio (file) {
|
function isAudio (file) {
|
||||||
var ext = path.extname(file.name).toLowerCase()
|
var ext = path.extname(file.name).toLowerCase()
|
||||||
return [
|
return [
|
||||||
'.mp3',
|
|
||||||
'.aac',
|
'.aac',
|
||||||
|
'.ac3',
|
||||||
|
'.mp3',
|
||||||
'.ogg',
|
'.ogg',
|
||||||
'.wav',
|
'.wav'
|
||||||
'.ac3'
|
].includes(ext)
|
||||||
].indexOf(ext) > -1
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function isPlayableTorrent (torrentSummary) {
|
function isPlayableTorrent (torrentSummary) {
|
||||||
|
|||||||
Reference in New Issue
Block a user