Skip to content

Commit

Permalink
Fix "no need for reference" clippy 1.81 lints
Browse files Browse the repository at this point in the history
  • Loading branch information
strohel committed Sep 13, 2024
1 parent 70e3636 commit c0e974d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ fn update_hosts_file(
for peer in peers {
hosts_builder.add_hostname(
peer.contents.ip,
&format!("{}.{}.wg", peer.contents.name, interface),
format!("{}.{}.wg", peer.contents.name, interface),
);
}
match hosts_builder.write_to(&hosts_path).with_path(&hosts_path) {
Expand Down Expand Up @@ -374,7 +374,7 @@ fn install(
if install_opts.delete_invite
|| Confirm::with_theme(&*prompts::THEME)
.wait_for_newline(true)
.with_prompt(&format!(
.with_prompt(format!(
"Delete invitation file \"{}\" now? (It's no longer needed)",
invite.to_string_lossy().yellow()
))
Expand Down Expand Up @@ -666,7 +666,7 @@ fn uninstall(interface: &InterfaceName, opts: &Opts, yes: bool) -> Result<(), Er

if yes
|| Confirm::with_theme(&*prompts::THEME)
.with_prompt(&format!(
.with_prompt(format!(
"Permanently delete network \"{}\"?",
interface.as_str_lossy().yellow()
))
Expand Down
2 changes: 1 addition & 1 deletion server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ fn uninstall(
) -> Result<(), Error> {
if yes
|| Confirm::with_theme(&*prompts::THEME)
.with_prompt(&format!(
.with_prompt(format!(
"Permanently delete network \"{}\"?",
interface.as_str_lossy().yellow()
))
Expand Down
2 changes: 1 addition & 1 deletion wireguard-control/src/backends/userspace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ fn start_userspace_wireguard(iface: &InterfaceName) -> io::Result<Output> {
command.args(&[iface.to_string()]).output()?
} else {
command
.env("WG_TUN_NAME_FILE", &format!("{VAR_RUN_PATH}/{iface}.name"))
.env("WG_TUN_NAME_FILE", format!("{VAR_RUN_PATH}/{iface}.name"))
.args(["utun"])
.output()?
};
Expand Down

0 comments on commit c0e974d

Please sign in to comment.