mirror of
https://github.com/TeamNewPipe/NewPipeExtractor.git
synced 2024-12-14 06:10:33 +05:30
Fix typo in DonationLinkHelper and rewrote swtich statement
This commit is contained in:
parent
2f02c0e6a4
commit
82746d172f
@ -15,16 +15,14 @@ public class DonationLinkHelper {
|
||||
AMAZON,
|
||||
}
|
||||
|
||||
public static DonationService getDonatoinServiceByLink(String link) throws MalformedURLException {
|
||||
public static DonationService getDonationServiceByLink(String link) throws MalformedURLException {
|
||||
URL url = new URL(fixLink(link));
|
||||
switch (url.getHost()) {
|
||||
case "www.patreon.com":
|
||||
return DonationService.PATREON;
|
||||
case "patreon.com":
|
||||
return DonationService.PATREON;
|
||||
case "paypal.me":
|
||||
return DonationService.PAYPAL;
|
||||
case "www.paypal.me":
|
||||
case "paypal.me":
|
||||
return DonationService.PAYPAL;
|
||||
default:
|
||||
return DonationService.NO_DONATION;
|
||||
|
Loading…
Reference in New Issue
Block a user