Skip to content
This repository was archived by the owner on Aug 22, 2025. It is now read-only.

Commit a70c44e

Browse files
committed
Remove condition to set ogg file as ogg job-type
1 parent fe86806 commit a70c44e

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

admin/rt-transcoder-handler.php

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ class RT_Transcoder_Handler {
8383
* @access public
8484
* @var string $audio_extensions Audio extensions with comma separated.
8585
*/
86-
public $audio_extensions = ',wma,wav,m4a';
86+
public $audio_extensions = ',wma,ogg,wav,m4a';
8787

8888
/**
8989
* Initialize the class and set its properties.
@@ -195,16 +195,15 @@ function wp_media_transcoding( $wp_metadata, $attachment_id, $autoformat = true
195195
$options_video_thumb = 5;
196196
}
197197

198+
$job_type = 'video';
198199
/** FORMAT * */
199200
if ( 'video/mp4' === $metadata['mime_type'] && 'mp4' === $type ) {
200201
$autoformat = 'thumbnails';
201202
$job_type = 'thumbnail';
202-
} elseif ( 'audio' === $type_array[0] || in_array( $extension, explode( ',', $this->audio_extensions ), true ) ) {
203+
}
204+
205+
if ( 'audio' === $type_array[0] || in_array( $extension, explode( ',', $this->audio_extensions ), true ) ) {
203206
$job_type = 'audio';
204-
} elseif ( 'application/ogg' === $metadata['mime_type'] ) {
205-
$job_type = 'ogg';
206-
} else {
207-
$job_type = 'video';
208207
}
209208

210209
/** Figure out who is requesting this job **/

0 commit comments

Comments
 (0)