diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-01-12 15:20:03 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-01-12 15:20:03 +0100 |
commit | 99fe265a5fc077cb66c322e7f3d191ff7110aea0 (patch) | |
tree | c9e04ccfcc5496d2300d7c26db5833e494b4cdad /client/src/app/admin/requests | |
parent | fcc5f77b95d330bfcb439c172b7fcc58f3162e4d (diff) | |
parent | 91cc839af88730ba55f84997c56b85ea100070a7 (diff) | |
download | PeerTube-99fe265a5fc077cb66c322e7f3d191ff7110aea0.tar.gz PeerTube-99fe265a5fc077cb66c322e7f3d191ff7110aea0.tar.zst PeerTube-99fe265a5fc077cb66c322e7f3d191ff7110aea0.zip |
Merge branch 'postgresql'
Diffstat (limited to 'client/src/app/admin/requests')
3 files changed, 5 insertions, 5 deletions
diff --git a/client/src/app/admin/requests/request-stats/request-stats.component.html b/client/src/app/admin/requests/request-stats/request-stats.component.html index b5ac59a9a..6698eac48 100644 --- a/client/src/app/admin/requests/request-stats/request-stats.component.html +++ b/client/src/app/admin/requests/request-stats/request-stats.component.html | |||
@@ -18,6 +18,6 @@ | |||
18 | 18 | ||
19 | <div> | 19 | <div> |
20 | <span class="label-description">Remaining requests:</span> | 20 | <span class="label-description">Remaining requests:</span> |
21 | {{ stats.requests.length }} | 21 | {{ stats.totalRequests }} |
22 | </div> | 22 | </div> |
23 | </div> | 23 | </div> |
diff --git a/client/src/app/admin/requests/request-stats/request-stats.component.ts b/client/src/app/admin/requests/request-stats/request-stats.component.ts index d20b12199..9e2af219c 100644 --- a/client/src/app/admin/requests/request-stats/request-stats.component.ts +++ b/client/src/app/admin/requests/request-stats/request-stats.component.ts | |||
@@ -19,7 +19,7 @@ export class RequestStatsComponent implements OnInit, OnDestroy { | |||
19 | } | 19 | } |
20 | 20 | ||
21 | ngOnDestroy() { | 21 | ngOnDestroy() { |
22 | if (this.stats.secondsInterval !== null) { | 22 | if (this.stats !== null && this.stats.secondsInterval !== null) { |
23 | clearInterval(this.interval); | 23 | clearInterval(this.interval); |
24 | } | 24 | } |
25 | } | 25 | } |
diff --git a/client/src/app/admin/requests/shared/request-stats.model.ts b/client/src/app/admin/requests/shared/request-stats.model.ts index 766e80836..49ecbc79e 100644 --- a/client/src/app/admin/requests/shared/request-stats.model.ts +++ b/client/src/app/admin/requests/shared/request-stats.model.ts | |||
@@ -7,18 +7,18 @@ export class RequestStats { | |||
7 | maxRequestsInParallel: number; | 7 | maxRequestsInParallel: number; |
8 | milliSecondsInterval: number; | 8 | milliSecondsInterval: number; |
9 | remainingMilliSeconds: number; | 9 | remainingMilliSeconds: number; |
10 | requests: Request[]; | 10 | totalRequests: number; |
11 | 11 | ||
12 | constructor(hash: { | 12 | constructor(hash: { |
13 | maxRequestsInParallel: number, | 13 | maxRequestsInParallel: number, |
14 | milliSecondsInterval: number, | 14 | milliSecondsInterval: number, |
15 | remainingMilliSeconds: number, | 15 | remainingMilliSeconds: number, |
16 | requests: Request[]; | 16 | totalRequests: number; |
17 | }) { | 17 | }) { |
18 | this.maxRequestsInParallel = hash.maxRequestsInParallel; | 18 | this.maxRequestsInParallel = hash.maxRequestsInParallel; |
19 | this.milliSecondsInterval = hash.milliSecondsInterval; | 19 | this.milliSecondsInterval = hash.milliSecondsInterval; |
20 | this.remainingMilliSeconds = hash.remainingMilliSeconds; | 20 | this.remainingMilliSeconds = hash.remainingMilliSeconds; |
21 | this.requests = hash.requests; | 21 | this.totalRequests = hash.totalRequests; |
22 | } | 22 | } |
23 | 23 | ||
24 | get remainingSeconds() { | 24 | get remainingSeconds() { |