Rename host -> url

Signed-off-by: Julio Zynger <julio.zynger@soundcloud.com>
This commit is contained in:
Julio Zynger
2022-03-01 10:32:47 +01:00
committed by Fredrik Adelöw
parent 171be275ae
commit 7bb98ee655
5 changed files with 11 additions and 13 deletions
+4 -5
View File
@@ -24,7 +24,7 @@ type Options = {
type PeriskopInstance = {
name: string;
host: string;
url: string;
};
/**
@@ -42,14 +42,13 @@ export class PeriskopApi {
.getConfigArray('periskop.instances')
.flatMap(locConf => {
const name = locConf.getString('name');
const host = locConf.getString('host');
return { name: name, host: host };
const url = locConf.getString('url');
return { name: name, url: url };
});
}
private getApiUrl(instanceName: string): string | undefined {
return this.instances.find(instance => instance.name === instanceName)
?.host;
return this.instances.find(instance => instance.name === instanceName)?.url;
}
getInstanceNames(): string[] {