History

refactor (#450)

Sebastian Thiel committed 4 years ago

Commit ce16f511 parent b66258f3 files · +8 −10Browse files

Showing the changes to git-credentials/src/program (1 of 3 files). Show all

Unified · Split

git-credentials/src/program/mod.rs+2−4
@@ -100,9 +100,7 @@ impl Helper for Program { · 99 unmodified lines
100100 let mut cmd = match &kind {
101101 Kind::Builtin => {
102102 let mut cmd = Command::new(cfg!(windows).then(|| "git.exe").unwrap_or("git"));
103− cmd.arg("credential")
104− .stderr(Stdio::null())
105− .arg(action.as_helper_arg(false));
103+ cmd.arg("credential").stderr(Stdio::null()).arg(action.as_arg(false));
106104 cmd
107105 }
108106 Kind::ExternalShellScript(for_shell)
@@ -113,7 +111,7 @@ impl Helper for Program { · 4 unmodified lines
113111 path_and_args: for_shell,
114112 } => git_command::prepare(git_path::from_bstr(for_shell.as_bstr()).as_ref())
115113 .with_shell()
116− .arg(action.as_helper_arg(true))
114+ .arg(action.as_arg(true))
117115 .into(),
118116 };
119117 cmd.stdin(Stdio::piped()).stdout(if action.expects_output() {