From 4e2b24f877a26f1916cc9904f30f368ce99c198b Mon Sep 17 00:00:00 2001 From: root Date: Thu, 18 Jun 2015 19:40:58 +0200 Subject: [PATCH] Handle opus audio files like ogg audio files --- lib/class/webplayer.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/class/webplayer.class.php b/lib/class/webplayer.class.php index 10e7be44..cf34a636 100644 --- a/lib/class/webplayer.class.php +++ b/lib/class/webplayer.class.php @@ -114,7 +114,7 @@ class WebPlayer } if ($urlinfo['type'] == 'song') { - if ($types['real'] == "ogg") $types['player'] = "oga"; + if ($types['real'] == "ogg" || $types['real'] == "opus") $types['player'] = "oga"; else if ($types['real'] == "mp4") $types['player'] = "m4a"; } else if ($urlinfo['type'] == 'video') { if ($types['real'] == "ogg") $types['player'] = "ogv"; @@ -123,7 +123,7 @@ class WebPlayer } } else if ($item->type == 'live_stream') { $types['real'] = $item->codec; - if ($types['real'] == "ogg") $types['player'] = "oga"; + if ($types['real'] == "ogg" || $types['real'] == "opus") $types['player'] = "oga"; } else { $ext = pathinfo($item->url, PATHINFO_EXTENSION); if (!empty($ext)) $types['real'] = $ext;