浏览代码

Fixes stash drop git command

main
Eric Amodio 4 年前
父节点
当前提交
545fc819e6
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. +3
    -1
      src/commands/git/stash.ts

+ 3
- 1
src/commands/git/stash.ts 查看文件

@ -381,8 +381,10 @@ export class StashGitCommand extends QuickCommand {
const result = yield* this.dropCommandConfirmStep(state, context);
if (result === StepResult.Break) continue;
QuickCommand.endSteps(state);
try {
void (await state.repo.stashDelete(`stash@{${state.reference.ref}}`));
// drop can only take a stash index, e.g. `stash@{1}`
void (await state.repo.stashDelete(`stash@{${state.reference.number}}`));
} catch (ex) {
Logger.error(ex, context.title);

正在加载...
取消
保存