Prevent remote subscribe on accounts
Which is not supported by PeerTube
This commit is contained in:
parent
3601872153
commit
5cea8f9567
|
@ -5,15 +5,16 @@
|
|||
|
||||
<ng-template #userLoggedOut>
|
||||
<span [ngClass]="{ 'extra-text': isAtLeastOneChannelSubscribed }">
|
||||
<ng-container *ngIf="account; then multiple; else single"></ng-container>
|
||||
<ng-template i18n #single>Subscribe</ng-template>
|
||||
<ng-template #multiple>
|
||||
<ng-container i18n *ngIf="isSingleSubscribe">Subscribe</ng-container>
|
||||
|
||||
<ng-container *ngIf="!isSingleSubscribe">
|
||||
<span i18n>Subscribe to all channels</span>
|
||||
<span *ngIf="isAtLeastOneChannelSubscribed">{{ subscribeStatus(true).length }}/{{ subscribed.size }}
|
||||
<ng-container i18n>channels subscribed</ng-container>
|
||||
</span>
|
||||
</ng-template>
|
||||
</ng-container>
|
||||
</span>
|
||||
|
||||
<span *ngIf="!isBigButton && displayFollowers && videoChannels.length > 1 && videoChannel.followersCount !== 0" class="followers-count">
|
||||
{{ videoChannels[0].followersCount | myNumberFormatter }}
|
||||
</span>
|
||||
|
|
|
@ -76,6 +76,10 @@ export class SubscribeButtonComponent implements OnInit, OnChanges {
|
|||
return this.isUserLoggedIn() && this.videoChannels.length > 1 && this.isAtLeastOneChannelSubscribed
|
||||
}
|
||||
|
||||
get isSingleSubscribe () {
|
||||
return !this.account
|
||||
}
|
||||
|
||||
ngOnInit () {
|
||||
this.loadSubscribedStatus()
|
||||
}
|
||||
|
@ -168,7 +172,7 @@ export class SubscribeButtonComponent implements OnInit, OnChanges {
|
|||
}
|
||||
|
||||
isRemoteSubscribeAvailable () {
|
||||
return !this.isUserLoggedIn()
|
||||
return this.isSingleSubscribe && !this.isUserLoggedIn()
|
||||
}
|
||||
|
||||
private getChannelHandler (videoChannel: VideoChannel) {
|
||||
|
|
Loading…
Reference in New Issue