Browse Source

Fixes retry action for Git commands

main
Eric Amodio 3 years ago
parent
commit
e6c7334b06
2 changed files with 7 additions and 2 deletions
  1. +6
    -0
      src/commands/quickCommand.buttons.ts
  2. +1
    -2
      src/commands/quickCommand.ts

+ 6
- 0
src/commands/quickCommand.buttons.ts View File

@ -37,6 +37,12 @@ export class ToggleQuickInputButton implements QuickInputButton {
this._on = value; this._on = value;
} }
/**
*
* @param quickInput
* @returns `true` if the step should be retried (refreshed)
*
*/
onDidClick?(quickInput: QuickInput): boolean | void | Promise<boolean | void>; onDidClick?(quickInput: QuickInput): boolean | void | Promise<boolean | void>;
private getState() { private getState() {

+ 1
- 2
src/commands/quickCommand.ts View File

@ -190,8 +190,7 @@ export abstract class QuickCommand implements QuickPickItem {
} }
async retry(): Promise<QuickPickStep | QuickInputStep | undefined> { async retry(): Promise<QuickPickStep | QuickInputStep | undefined> {
await this.next(Directive.Back);
await this.next();
await this.next(Directive.Noop);
return this.value; return this.value;
} }

Loading…
Cancel
Save