mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-14 04:20:49 +08:00
Update TechnicalInformation.php
1. Added "Title" info into audio and subtitles items of mediainfo extra 2. Corrected the incorrect spelling of variables in getSubtitles function
This commit is contained in:
@@ -98,6 +98,9 @@ class TechnicalInformation
|
||||
if (!empty($values['Language'])) {
|
||||
$audioInfoArr[] = $values['Language'];
|
||||
}
|
||||
if (!empty($values['Title'])) {
|
||||
$audioInfoArr[] = $values['Title'];
|
||||
}
|
||||
if (!empty($values['Format'])) {
|
||||
$audioInfoArr[] = $values['Format'];
|
||||
}
|
||||
@@ -121,15 +124,18 @@ class TechnicalInformation
|
||||
if (strpos($parentKey, 'Text') === false) {
|
||||
continue;
|
||||
}
|
||||
$audioInfoArr = [];
|
||||
$subtitlesInfoArr = [];
|
||||
if (!empty($values['Language'])) {
|
||||
$audioInfoArr[] = $values['Language'];
|
||||
$subtitlesInfoArr[] = $values['Language'];
|
||||
}
|
||||
if (!empty($values['Title'])) {
|
||||
$subtitlesInfoArr[] = $values['Title'];
|
||||
}
|
||||
if (!empty($values['Format'])) {
|
||||
$audioInfoArr[] = $values['Format'];
|
||||
$subtitlesInfoArr[] = $values['Format'];
|
||||
}
|
||||
if (!empty($audioInfoArr)) {
|
||||
$result[$parentKey] = implode(" ", $audioInfoArr);
|
||||
if (!empty($subtitlesInfoArr)) {
|
||||
$result[$parentKey] = implode(" ", $subtitlesInfoArr);
|
||||
}
|
||||
}
|
||||
return $result;
|
||||
|
||||
Reference in New Issue
Block a user