Skip to content

Commit d835b06

Browse files
authored
fix: prevent duplicate MSO after table (#1267)
* fix: prevent duplicate MSO after table * chore: always stop stages in catch
1 parent 406e164 commit d835b06

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/commands/project/deploy/start.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,7 @@ export default class DeployMetadata extends SfCommand<DeployResultJson> {
279279

280280
const result = await deploy.pollStatus({ timeout: flags.wait });
281281
process.exitCode = determineExitCode(result);
282+
this.stages.stop();
282283
const formatter = new DeployResultFormatter(result, flags);
283284

284285
if (!this.jsonEnabled()) {
@@ -292,10 +293,11 @@ export default class DeployMetadata extends SfCommand<DeployResultJson> {
292293
}
293294

294295
protected catch(error: Error | SfError): Promise<never> {
296+
this.stages?.update({ status: 'Failed' });
297+
this.stages?.error();
298+
295299
if (error instanceof SourceConflictError && error.data) {
296300
if (!this.jsonEnabled()) {
297-
this.stages?.update({ status: 'Failed' });
298-
this.stages?.error();
299301
writeConflictTable(error.data);
300302
// set the message and add plugin-specific actions
301303
return super.catch({

0 commit comments

Comments
 (0)