Add requested changes.
Co-authored-by: TiA4f8R <74829229+TiA4f8R@users.noreply.github.com> Add final. Co-authored-by: TiA4f8R <74829229+TiA4f8R@users.noreply.github.com>
This commit is contained in:
parent
94efe86c71
commit
d1add05bc1
2 changed files with 6 additions and 4 deletions
|
@ -293,11 +293,13 @@ public class YoutubeStreamInfoItemExtractor implements StreamInfoItemExtractor {
|
|||
@Override
|
||||
public String getShortDescription() throws ParsingException {
|
||||
|
||||
if(videoInfo.has("detailedMetadataSnippets"))
|
||||
if (videoInfo.has("detailedMetadataSnippets")) {
|
||||
return getTextFromObject(videoInfo.getArray("detailedMetadataSnippets").getObject(0).getObject("snippetText"));
|
||||
}
|
||||
|
||||
if(videoInfo.has("descriptionSnippet"))
|
||||
return getTextFromObject(videoInfo.getObject("descriptionSnippet"));
|
||||
if (videoInfo.has("descriptionSnippet")) {
|
||||
return getTextFromObject(videoInfo.getObject("descriptionSnippet"));
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
|
|
@ -97,7 +97,7 @@ public class StreamInfoItem extends InfoItem {
|
|||
return shortDescription;
|
||||
}
|
||||
|
||||
public void setShortDescription(String shortDescription) {
|
||||
public void setShortDescription(final String shortDescription) {
|
||||
this.shortDescription = shortDescription;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue