From a2735c4f9765ff28bd967483dda2154ae3a2e8e6 Mon Sep 17 00:00:00 2001 From: Ritvik Saraf <13ritvik@gmail.com> Date: Sat, 2 Mar 2019 02:48:05 +0530 Subject: [PATCH 1/2] fix comment url --- .../youtube/extractors/YoutubeCommentsExtractor.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/extractors/YoutubeCommentsExtractor.java b/extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/extractors/YoutubeCommentsExtractor.java index 85d150014..aba43b2e8 100644 --- a/extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/extractors/YoutubeCommentsExtractor.java +++ b/extractor/src/main/java/org/schabi/newpipe/extractor/services/youtube/extractors/YoutubeCommentsExtractor.java @@ -107,11 +107,11 @@ public class YoutubeCommentsExtractor extends CommentsExtractor { throw new ParsingException("Could not parse json data for comments", e); } CommentsInfoItemsCollector collector = new CommentsInfoItemsCollector(getServiceId()); - collectCommentsFrom(collector, ajaxJson, pageUrl); + collectCommentsFrom(collector, ajaxJson); return new InfoItemsPage<>(collector, getNextPageUrl(ajaxJson)); } - private void collectCommentsFrom(CommentsInfoItemsCollector collector, JsonObject ajaxJson, String pageUrl) throws ParsingException { + private void collectCommentsFrom(CommentsInfoItemsCollector collector, JsonObject ajaxJson) throws ParsingException { JsonArray contents; try { @@ -130,7 +130,7 @@ public class YoutubeCommentsExtractor extends CommentsExtractor { for(Object c: comments) { if(c instanceof JsonObject) { - CommentsInfoItemExtractor extractor = new YoutubeCommentsInfoItemExtractor((JsonObject) c, pageUrl); + CommentsInfoItemExtractor extractor = new YoutubeCommentsInfoItemExtractor((JsonObject) c, getUrl()); collector.commit(extractor); } } From cb30b336ab73b4957f67bda05b639948ee0dd0e8 Mon Sep 17 00:00:00 2001 From: Ritvik Saraf <13ritvik@gmail.com> Date: Mon, 11 Mar 2019 02:14:58 +0530 Subject: [PATCH 2/2] set soundcloud default kiosk --- .../newpipe/extractor/services/soundcloud/SoundcloudService.java | 1 + 1 file changed, 1 insertion(+) diff --git a/extractor/src/main/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudService.java b/extractor/src/main/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudService.java index 74d38be57..d2387d3c2 100644 --- a/extractor/src/main/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudService.java +++ b/extractor/src/main/java/org/schabi/newpipe/extractor/services/soundcloud/SoundcloudService.java @@ -95,6 +95,7 @@ public class SoundcloudService extends StreamingService { try { list.addKioskEntry(chartsFactory, h, "Top 50"); list.addKioskEntry(chartsFactory, h, "New & hot"); + list.setDefaultKiosk("New & hot"); } catch (Exception e) { throw new ExtractionException(e); }