From 405ec98b916df9afb114ad20e847221d4eb94eea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Frank=20Str=C3=A4ter?= Date: Tue, 24 Sep 2019 14:43:11 +0200 Subject: Change button with onclick to link with href --- .../user-subscription/subscribe-button.component.html | 2 +- .../user-subscription/subscribe-button.component.ts | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) (limited to 'client/src') diff --git a/client/src/app/shared/user-subscription/subscribe-button.component.html b/client/src/app/shared/user-subscription/subscribe-button.component.html index c4dec239f..25f3be215 100644 --- a/client/src/app/shared/user-subscription/subscribe-button.component.html +++ b/client/src/app/shared/user-subscription/subscribe-button.component.html @@ -46,7 +46,7 @@ - + Subscribe via RSS diff --git a/client/src/app/shared/user-subscription/subscribe-button.component.ts b/client/src/app/shared/user-subscription/subscribe-button.component.ts index 25515f6ea..b04e230f0 100644 --- a/client/src/app/shared/user-subscription/subscribe-button.component.ts +++ b/client/src/app/shared/user-subscription/subscribe-button.component.ts @@ -36,6 +36,14 @@ export class SubscribeButtonComponent implements OnInit { return this.videoChannel.url } + get rssUri () { + const rssFeed = this.videoService + .getVideoChannelFeedUrls(this.videoChannel.id) + .find(i => i.format === FeedFormat.RSS) + + return rssFeed.url + } + ngOnInit () { if (this.isUserLoggedIn()) { this.userSubscriptionService.doesSubscriptionExist(this.channelHandle) @@ -100,12 +108,4 @@ export class SubscribeButtonComponent implements OnInit { gotoLogin () { this.router.navigate([ '/login' ]) } - - rssOpen () { - const rssFeed = this.videoService - .getVideoChannelFeedUrls(this.videoChannel.id) - .find(i => i.format === FeedFormat.RSS) - - window.open(rssFeed.url) - } } -- cgit v1.2.3