Skip to content

Commit

Permalink
πŸ› ExecOptions.yank should be optional
Browse files Browse the repository at this point in the history
  • Loading branch information
atusy committed Nov 11, 2023
1 parent ac2d5bc commit c0ac358
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions denops/gin/command/browse/command.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ import { yank } from "../../util/yank.ts";

export type ExecOptions = Omit<Options, "cwd" | "aliases"> & {
worktree?: string;
yank: string | boolean;
yank?: string | boolean;
noBrowser?: boolean;
};

export async function exec(
denops: Denops,
commitish: string,
options: ExecOptions = { yank: false },
options: ExecOptions = {},
): Promise<void> {
const [verbose, aliases] = await batch.collect(denops, (denops) => [
option.verbose.get(denops),
Expand Down Expand Up @@ -56,7 +56,7 @@ export async function exec(
aliases,
});

if (options.yank !== false) {
if (options.yank != null && options.yank !== false) {
await yank(
denops,
url.href,
Expand Down

0 comments on commit c0ac358

Please sign in to comment.