From 1631f996f2f9f9c10847d7f423e6fc7495bf49c3 Mon Sep 17 00:00:00 2001 From: FireMasterK <20838718+FireMasterK@users.noreply.github.com> Date: Sun, 15 Aug 2021 21:59:49 +0530 Subject: [PATCH] Add verified info to ChannelInfo. --- .../newpipe/extractor/channel/ChannelInfo.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/extractor/src/main/java/org/schabi/newpipe/extractor/channel/ChannelInfo.java b/extractor/src/main/java/org/schabi/newpipe/extractor/channel/ChannelInfo.java index 6863e60286..00201358af 100644 --- a/extractor/src/main/java/org/schabi/newpipe/extractor/channel/ChannelInfo.java +++ b/extractor/src/main/java/org/schabi/newpipe/extractor/channel/ChannelInfo.java @@ -113,6 +113,12 @@ public static ChannelInfo getInfo(ChannelExtractor extractor) throws IOException info.addError(e); } + try { + info.setVerified(extractor.isVerified()); + } catch (Exception e) { + info.addError(e); + } + return info; } @@ -125,6 +131,7 @@ public static ChannelInfo getInfo(ChannelExtractor extractor) throws IOException private long subscriberCount = -1; private String description; private String[] donationLinks; + private boolean verified; public String getParentChannelName() { return parentChannelName; @@ -197,4 +204,12 @@ public String[] getDonationLinks() { public void setDonationLinks(String[] donationLinks) { this.donationLinks = donationLinks; } + + public boolean isVerified() { + return verified; + } + + public void setVerified(boolean verified) { + this.verified = verified; + } }