mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-04 15:26:43 +02:00
chore: update CodeIgniter to 4.5.1 + other dependencies to latest
This commit is contained in:
parent
303a900f66
commit
d4a36f811b
103 changed files with 3079 additions and 2745 deletions
|
|
@ -85,16 +85,12 @@ class Transcript extends BaseMedia
|
|||
}
|
||||
|
||||
$transcript_format = $this->file->getExtension();
|
||||
switch ($transcript_format) {
|
||||
case 'vtt':
|
||||
$transcriptJson = $transcriptParser->loadString($transcriptContent)
|
||||
->parseVtt();
|
||||
break;
|
||||
case 'srt':
|
||||
default:
|
||||
$transcriptJson = $transcriptParser->loadString($transcriptContent)
|
||||
->parseSrt();
|
||||
}
|
||||
$transcriptJson = match ($transcript_format) {
|
||||
'vtt' => $transcriptParser->loadString($transcriptContent)
|
||||
->parseVtt(),
|
||||
default => $transcriptParser->loadString($transcriptContent)
|
||||
->parseSrt(),
|
||||
};
|
||||
|
||||
$tempFilePath = WRITEPATH . 'uploads/' . $this->file->getRandomName();
|
||||
file_put_contents($tempFilePath, $transcriptJson);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue