aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared/video-channel
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-05-25 09:57:16 +0200
committerChocobozzz <me@florianbigard.com>2018-05-25 10:41:07 +0200
commitad9e39fb815d85e5e718c40540fa75471474fa17 (patch)
tree960accb16bca0fac7694b3f3d5d038534b66c224 /client/src/app/shared/video-channel
parent06be7ed0b27b371465c5d1b7f92b4adfb0b866ea (diff)
downloadPeerTube-ad9e39fb815d85e5e718c40540fa75471474fa17.tar.gz
PeerTube-ad9e39fb815d85e5e718c40540fa75471474fa17.tar.zst
PeerTube-ad9e39fb815d85e5e718c40540fa75471474fa17.zip
Only use account name in routes
Diffstat (limited to 'client/src/app/shared/video-channel')
-rw-r--r--client/src/app/shared/video-channel/video-channel.service.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/client/src/app/shared/video-channel/video-channel.service.ts b/client/src/app/shared/video-channel/video-channel.service.ts
index e1e3bf697..55e4c2a31 100644
--- a/client/src/app/shared/video-channel/video-channel.service.ts
+++ b/client/src/app/shared/video-channel/video-channel.service.ts
@@ -8,6 +8,7 @@ import { AccountService } from '../account/account.service'
8import { ResultList } from '../../../../../shared' 8import { ResultList } from '../../../../../shared'
9import { VideoChannel } from './video-channel.model' 9import { VideoChannel } from './video-channel.model'
10import { environment } from '../../../environments/environment' 10import { environment } from '../../../environments/environment'
11import { Account } from '@app/shared/account/account.model'
11 12
12@Injectable() 13@Injectable()
13export class VideoChannelService { 14export class VideoChannelService {
@@ -29,8 +30,8 @@ export class VideoChannelService {
29 ) 30 )
30 } 31 }
31 32
32 listAccountVideoChannels (accountId: number): Observable<ResultList<VideoChannel>> { 33 listAccountVideoChannels (account: Account): Observable<ResultList<VideoChannel>> {
33 return this.authHttp.get<ResultList<VideoChannelServer>>(AccountService.BASE_ACCOUNT_URL + accountId + '/video-channels') 34 return this.authHttp.get<ResultList<VideoChannelServer>>(AccountService.BASE_ACCOUNT_URL + account.nameWithHost + '/video-channels')
34 .pipe( 35 .pipe(
35 map(res => this.extractVideoChannels(res)), 36 map(res => this.extractVideoChannels(res)),
36 catchError((res) => this.restExtractor.handleError(res)) 37 catchError((res) => this.restExtractor.handleError(res))