Mapping of m3u, m3u8, pls to audio streams

Signed-Off-By: Rello <Rello@users.noreply.github.com>
This commit is contained in:
Rello 2017-08-31 17:48:49 +02:00 committed by Joas Schilling
parent 84f3d247f2
commit c5f76785ba
No known key found for this signature in database
GPG Key ID: 7076EA9751AACDDA
2 changed files with 17 additions and 0 deletions

View File

@ -149,6 +149,16 @@ class RepairMimeTypes implements IRepairStep {
$this->updateMimetypes($updatedMimetypes);
}
private function introduceStreamingTypes() {
$updatedMimetypes = [
'm3u' => 'audio/mpegurl',
'm3u8' => 'audio/mpegurl',
'pls' => 'audio/x-scpls'
];
$this->updateMimetypes($updatedMimetypes);
}
/**
* Fix mime types
*/
@ -174,5 +184,9 @@ class RepairMimeTypes implements IRepairStep {
if (version_compare($ocVersionFromBeforeUpdate, '13.0.0.3', '<') && $this->introduceInternetShortcutTypes()) {
$out->info('Fixed internet-shortcut mime types');
}
if (version_compare($ocVersionFromBeforeUpdate, '13.0.0.6', '<') && $this->introduceStreamingTypes()) {
$out->info('Fixed streaming mime types');
}
}
}

View File

@ -88,6 +88,8 @@
"ldif": ["text/x-ldif"],
"lwp": ["application/vnd.lotus-wordpro"],
"m2t": ["video/mp2t"],
"m3u": ["audio/mpegurl"],
"m3u8": ["audio/mpegurl"],
"m4a": ["audio/mp4"],
"m4b": ["audio/m4b"],
"m4v": ["video/mp4"],
@ -129,6 +131,7 @@
"pef": ["image/x-dcraw"],
"php": ["application/x-php"],
"pl": ["application/x-perl"],
"pls": ["audio/x-scpls"],
"png": ["image/png"],
"pot": ["application/vnd.ms-powerpoint"],
"potm": ["application/vnd.ms-powerpoint.template.macroEnabled.12"],