mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-23 09:35:39 -05:00
Fix resultSerializer to correctly check returned file picker path (#6713)
This commit is contained in:
@@ -130,7 +130,7 @@ export class ResultSerializer {
|
||||
}
|
||||
|
||||
|
||||
private promptForFilepath(format: SaveFormat, resourceUri: string): Thenable<string> {
|
||||
private promptForFilepath(format: SaveFormat, resourceUri: string): Thenable<string | undefined> {
|
||||
let filepathPlaceHolder = prevSavePath ? path.dirname(prevSavePath) : resolveCurrentDirectory(resourceUri, this.rootPath);
|
||||
if (filepathPlaceHolder) {
|
||||
filepathPlaceHolder = path.join(filepathPlaceHolder, this.getResultsDefaultFilename(format));
|
||||
@@ -141,8 +141,11 @@ export class ResultSerializer {
|
||||
defaultUri: filepathPlaceHolder ? URI.file(filepathPlaceHolder) : undefined,
|
||||
filters: this.getResultsFileExtension(format)
|
||||
}).then(filePath => {
|
||||
prevSavePath = filePath.fsPath;
|
||||
return filePath.fsPath;
|
||||
if (filePath) {
|
||||
prevSavePath = filePath.fsPath;
|
||||
return filePath.fsPath;
|
||||
}
|
||||
return undefined;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user