Skip to content

Commit

Permalink
chore: apply clippy feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
lklimek committed Oct 25, 2023
1 parent f413119 commit 6da0808
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion abci/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ impl<'a, App: RequestDispatcher + 'a> ServerBuilder<App> {
let _guard = server_runtime.handle.enter();

// No cancel is defined, so we add some "mock"
let cancel = self.cancel.unwrap_or(CancellationToken::new());
let cancel = self.cancel.unwrap_or_default();

let server = match bind_address.scheme() {
#[cfg(feature = "tcp")]
Expand Down
12 changes: 6 additions & 6 deletions abci/src/server/codec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,12 +230,12 @@ mod test {
let codec = tokio_util::codec::Framed::new(server, super::Coder {});

let worker_cancel = cancel.clone();
let hdl = tokio::spawn(
async move {
super::Codec::process_worker_queues(codec, request_tx, response_rx, worker_cancel)
}
.await,
);
let hdl = tokio::spawn(super::Codec::process_worker_queues(
codec,
request_tx,
response_rx,
worker_cancel,
));

// We send 2 requests over the wire
for n_requests in 0..5 {
Expand Down
6 changes: 3 additions & 3 deletions abci/tests/common/docker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -153,14 +153,14 @@ impl TenderdashDocker {
None
};

let app_address = app_address.to_string().replace("/", "\\/");
let app_address = app_address.to_string().replace('/', "\\/");

debug!("Tenderdash will connect to ABCI address: {}", app_address);
let container_config = Config {
image: Some(self.image.clone()),
env: Some(vec![format!("PROXY_APP={}", app_address)]),
host_config: Some(HostConfig {
binds: binds,
binds,
..Default::default()
}),
..Default::default()
Expand Down Expand Up @@ -215,7 +215,7 @@ impl TenderdashDocker {
let mut dest = tokio::io::BufWriter::new(stderror);

let mut logs = docker.logs(
&id,
id,
Some(bollard::container::LogsOptions {
follow: false,
stdout: true,
Expand Down

0 comments on commit 6da0808

Please sign in to comment.