Skip to content

Commit 2bbe6e6

Browse files
committed
fix: strip path sep too
1 parent 403d215 commit 2bbe6e6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/commands/project/retrieve/start.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*/
77

88
import { rm } from 'node:fs/promises';
9-
import { dirname, join, resolve } from 'node:path';
9+
import { dirname, join, resolve, sep } from 'node:path';
1010
import * as fs from 'node:fs';
1111

1212
import { MultiStageOutput } from '@oclif/multi-stage-output';
@@ -366,7 +366,7 @@ export default class RetrieveMetadata extends SfCommand<RetrieveResultJson> {
366366

367367
// getFileResponses fails once the files have been moved, calculate where they're moved to, and then move them
368368
this.retrieveResult.getFileResponses().forEach((fileResponse) => {
369-
fileResponse.filePath = fileResponse.filePath?.replace(join('main', 'default'), '');
369+
fileResponse.filePath = fileResponse.filePath?.replace(join('main', 'default', sep), '');
370370
});
371371
// move contents of 'main/default' to 'retrievetargetdir'
372372
await promisesQueue([join(resolvedTargetDir, 'main', 'default')], mv, 5, true);

0 commit comments

Comments
 (0)