mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-23 11:28:59 +00:00
update system config url and http options
This commit is contained in:
parent
838b2a6a34
commit
fb4c7d288c
@ -20,16 +20,16 @@ export class SystemConfigService {
|
||||
private devices: Device[];
|
||||
private foldersSubject: Subject<Folder[]> = new Subject();
|
||||
private devicesSubject: Subject<Device[]> = new Subject();
|
||||
private systemConfigUrl = environment.production ? apiURL + '/rest/system/config' : 'api/config';
|
||||
private systemConfigUrl = environment.production ? apiURL + 'rest/system/config' : 'api/config';
|
||||
|
||||
private httpOptions;
|
||||
|
||||
constructor(private http: HttpClient, private cookieService: CookieService) { }
|
||||
|
||||
ngOnInit(): void {
|
||||
constructor(private http: HttpClient, private cookieService: CookieService) {
|
||||
this.httpOptions = { headers: new HttpHeaders(this.cookieService.getCSRFHeader()) };
|
||||
}
|
||||
|
||||
ngOnInit(): void { }
|
||||
|
||||
getSystemConfig(): Observable<any> {
|
||||
return this.http
|
||||
.get(this.systemConfigUrl, this.httpOptions)
|
||||
|
Loading…
Reference in New Issue
Block a user