diff options
author | Chocobozzz <me@florianbigard.com> | 2018-05-15 11:55:51 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-05-16 09:42:54 +0200 |
commit | db400f447a9f7aae1c56fa25396e93069744483f (patch) | |
tree | f45af832a5d3f4eebafd2f885b7413d9f84fa374 /client/src/app/+admin/config | |
parent | 54c3a22faa04bf13eea37f39be9149fc5eb95737 (diff) | |
download | PeerTube-db400f447a9f7aae1c56fa25396e93069744483f.tar.gz PeerTube-db400f447a9f7aae1c56fa25396e93069744483f.tar.zst PeerTube-db400f447a9f7aae1c56fa25396e93069744483f.zip |
Upgrade to rxjs 6
Diffstat (limited to 'client/src/app/+admin/config')
-rw-r--r-- | client/src/app/+admin/config/shared/config.service.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/client/src/app/+admin/config/shared/config.service.ts b/client/src/app/+admin/config/shared/config.service.ts index 2a39c7155..1565774b3 100644 --- a/client/src/app/+admin/config/shared/config.service.ts +++ b/client/src/app/+admin/config/shared/config.service.ts | |||
@@ -1,3 +1,4 @@ | |||
1 | import { catchError } from 'rxjs/operators' | ||
1 | import { HttpClient } from '@angular/common/http' | 2 | import { HttpClient } from '@angular/common/http' |
2 | import { Injectable } from '@angular/core' | 3 | import { Injectable } from '@angular/core' |
3 | import { CustomConfig } from '../../../../../../shared/models/server/custom-config.model' | 4 | import { CustomConfig } from '../../../../../../shared/models/server/custom-config.model' |
@@ -16,11 +17,11 @@ export class ConfigService { | |||
16 | 17 | ||
17 | getCustomConfig () { | 18 | getCustomConfig () { |
18 | return this.authHttp.get<CustomConfig>(ConfigService.BASE_APPLICATION_URL + '/custom') | 19 | return this.authHttp.get<CustomConfig>(ConfigService.BASE_APPLICATION_URL + '/custom') |
19 | .catch(res => this.restExtractor.handleError(res)) | 20 | .pipe(catchError(res => this.restExtractor.handleError(res))) |
20 | } | 21 | } |
21 | 22 | ||
22 | updateCustomConfig (data: CustomConfig) { | 23 | updateCustomConfig (data: CustomConfig) { |
23 | return this.authHttp.put<CustomConfig>(ConfigService.BASE_APPLICATION_URL + '/custom', data) | 24 | return this.authHttp.put<CustomConfig>(ConfigService.BASE_APPLICATION_URL + '/custom', data) |
24 | .catch(res => this.restExtractor.handleError(res)) | 25 | .pipe(catchError(res => this.restExtractor.handleError(res))) |
25 | } | 26 | } |
26 | } | 27 | } |