Escape vault name
This commit is contained in:
parent
d39a91b447
commit
8ef2f8c132
1 changed files with 15 additions and 17 deletions
|
|
@ -88,8 +88,7 @@ export class SyncService {
|
|||
}
|
||||
|
||||
this.logger.debug(
|
||||
`Created document ${JSON.stringify(result)} with id ${
|
||||
result.documentId
|
||||
`Created document ${JSON.stringify(result)} with id ${result.documentId
|
||||
}`
|
||||
);
|
||||
|
||||
|
|
@ -140,8 +139,7 @@ export class SyncService {
|
|||
}
|
||||
|
||||
this.logger.debug(
|
||||
`Updated document ${JSON.stringify(result)} with id ${
|
||||
result.documentId
|
||||
`Updated document ${JSON.stringify(result)} with id ${result.documentId
|
||||
}}`
|
||||
);
|
||||
|
||||
|
|
@ -193,8 +191,7 @@ export class SyncService {
|
|||
}
|
||||
|
||||
this.logger.debug(
|
||||
`Updated document ${JSON.stringify(result)} with id ${
|
||||
result.documentId
|
||||
`Updated document ${JSON.stringify(result)} with id ${result.documentId
|
||||
}}`
|
||||
);
|
||||
|
||||
|
|
@ -325,7 +322,8 @@ export class SyncService {
|
|||
private getUrl(path: string): string {
|
||||
const { vaultName, remoteUri } = this.settings.getSettings();
|
||||
const remoteUriWithoutTrailingSlash = remoteUri.replace(/\/+$/, "");
|
||||
return `${remoteUriWithoutTrailingSlash}/vaults/${vaultName}${path}`;
|
||||
const encodedVaultName = encodeURIComponent(vaultName.trim());
|
||||
return `${remoteUriWithoutTrailingSlash}/vaults/${encodedVaultName}${path}`;
|
||||
}
|
||||
|
||||
private getDefaultHeaders(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue