diff options
author | Chocobozzz <me@florianbigard.com> | 2021-08-17 14:42:53 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-08-18 08:35:06 +0200 |
commit | 9df52d660feb722404be00a50f3c8a612bec1c15 (patch) | |
tree | dde52880fa012874d24c60f64eb596b0a789cc8b /client/src/app/+accounts/accounts.component.ts | |
parent | adb8809d43648ea0a64d6845bb39aa3bd0e005a6 (diff) | |
download | PeerTube-9df52d660feb722404be00a50f3c8a612bec1c15.tar.gz PeerTube-9df52d660feb722404be00a50f3c8a612bec1c15.tar.zst PeerTube-9df52d660feb722404be00a50f3c8a612bec1c15.zip |
Migrate client to eslint
Diffstat (limited to 'client/src/app/+accounts/accounts.component.ts')
-rw-r--r-- | client/src/app/+accounts/accounts.component.ts | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/client/src/app/+accounts/accounts.component.ts b/client/src/app/+accounts/accounts.component.ts index 25eb13588..733cff8d5 100644 --- a/client/src/app/+accounts/accounts.component.ts +++ b/client/src/app/+accounts/accounts.component.ts | |||
@@ -61,7 +61,7 @@ export class AccountsComponent implements OnInit, OnDestroy { | |||
61 | ngOnInit () { | 61 | ngOnInit () { |
62 | this.routeSub = this.route.params | 62 | this.routeSub = this.route.params |
63 | .pipe( | 63 | .pipe( |
64 | map(params => params[ 'accountId' ]), | 64 | map(params => params['accountId']), |
65 | distinctUntilChanged(), | 65 | distinctUntilChanged(), |
66 | switchMap(accountId => this.accountService.getAccount(accountId)), | 66 | switchMap(accountId => this.accountService.getAccount(accountId)), |
67 | tap(account => this.onAccount(account)), | 67 | tap(account => this.onAccount(account)), |
@@ -72,7 +72,9 @@ export class AccountsComponent implements OnInit, OnDestroy { | |||
72 | ])) | 72 | ])) |
73 | ) | 73 | ) |
74 | .subscribe({ | 74 | .subscribe({ |
75 | next: videoChannels => this.videoChannels = videoChannels.data, | 75 | next: videoChannels => { |
76 | this.videoChannels = videoChannels.data | ||
77 | }, | ||
76 | 78 | ||
77 | error: err => this.notifier.error(err.message) | 79 | error: err => this.notifier.error(err.message) |
78 | }) | 80 | }) |
@@ -176,7 +178,9 @@ export class AccountsComponent implements OnInit, OnDestroy { | |||
176 | if (user.hasRight(UserRight.MANAGE_USERS)) { | 178 | if (user.hasRight(UserRight.MANAGE_USERS)) { |
177 | this.userService.getUser(account.userId) | 179 | this.userService.getUser(account.userId) |
178 | .subscribe({ | 180 | .subscribe({ |
179 | next: accountUser => this.accountUser = accountUser, | 181 | next: accountUser => { |
182 | this.accountUser = accountUser | ||
183 | }, | ||
180 | 184 | ||
181 | error: err => this.notifier.error(err.message) | 185 | error: err => this.notifier.error(err.message) |
182 | }) | 186 | }) |
@@ -209,6 +213,8 @@ export class AccountsComponent implements OnInit, OnDestroy { | |||
209 | itemsPerPage: 0 | 213 | itemsPerPage: 0 |
210 | }, | 214 | }, |
211 | sort: '-publishedAt' | 215 | sort: '-publishedAt' |
212 | }).subscribe(res => this.accountVideosCount = res.total) | 216 | }).subscribe(res => { |
217 | this.accountVideosCount = res.total | ||
218 | }) | ||
213 | } | 219 | } |
214 | } | 220 | } |