Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Commit

Permalink
Merge bce664b into c2318c3
Browse files Browse the repository at this point in the history
  • Loading branch information
yiyione committed Jul 16, 2020
2 parents c2318c3 + bce664b commit 67e29d3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/api/v2/clients/baseClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ export class OpenPAIBaseClient {
constructor(cluster: IPAICluster) {
this.cluster = OpenPAIBaseClient.parsePaiUri(cluster);
this.httpClient = new PAIHttpClient(cluster);

if (this.cluster.rest_server_uri) {
this.cluster.rest_server_uri = this.cluster.rest_server_uri
.toString()
.replace(/\/+$/, '');
}
}

/**
Expand All @@ -48,8 +54,6 @@ export class OpenPAIBaseClient {
if (!cluster.alias) {
cluster.alias = paiUri.hostname;
}

cluster.rest_server_uri = cluster.rest_server_uri.replace(/\/+$/, '');
}
return cluster;
}
Expand Down

0 comments on commit 67e29d3

Please sign in to comment.