diff --git a/core/music.php b/core/music.php index f15fd0d..56892c4 100644 --- a/core/music.php +++ b/core/music.php @@ -5,7 +5,7 @@ * * @author MaiCong * @link https://github.com/maicong/music - * @since 1.6.0 + * @since 1.6.1 * */ @@ -832,10 +832,12 @@ function mc_get_song_by_id($songid, $site = 'netease', $multi = false) if ($radio_lrc_urls) { $radio_lrc = jsonp2json(mc_curl($radio_lrc_urls)); } + $radio_music = 'http://' . str_replace('ws', 'dl', $radio_url[$value['id']]); if (!empty($radio_vkey['key'])) { - $radio_music = generate_qqmusic_url($radio_song_id, $radio_vkey['key']); - } else { - $radio_music = 'http://' . str_replace('ws', 'dl', $radio_url[$value['id']]); + $radio_music = generate_qqmusic_url( + $radio_song_id, + $radio_vkey['key'] + ) ?: $radio_music; } $radio_album_id = $value['album']['mid']; $radio_songs[] = [ diff --git a/index.php b/index.php index af60e80..faf41d6 100644 --- a/index.php +++ b/index.php @@ -5,7 +5,7 @@ * * @author MaiCong * @link https://github.com/maicong/music - * @since 1.6.0 + * @since 1.6.1 * */ @@ -13,7 +13,7 @@ define('MC_CORE', true); // 定义版本 -define('MC_VERSION', '1.6.0'); +define('MC_VERSION', '1.6.1'); // 核心文件目录 define('MC_CORE_DIR', __DIR__ . '/core');