Skip to content

Commit 3332d1c

Browse files
authoredApr 7, 2022
Fix YouTube track data
Thank you sedmelluq#687
1 parent c69457e commit 3332d1c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed
 

‎main/src/main/java/com/sedmelluq/discord/lavaplayer/source/youtube/YoutubeTrackJsonData.java

+5
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@ public static YoutubeTrackJsonData fromMainResult(JsonBrowser result) {
2929
JsonBrowser playerInfo = NULL_BROWSER;
3030
JsonBrowser playerResponse = NULL_BROWSER;
3131

32+
if (result.isMap()) {
33+
playerInfo = result.get("player");
34+
playerResponse = result.get("playerResponse");
35+
}
36+
3237
for (JsonBrowser child : result.values()) {
3338
if (child.isMap()) {
3439
if (playerInfo.isNull()) {

0 commit comments

Comments
 (0)
Please sign in to comment.