From 7d478d997620c0af41a6ffb8b3f29dc6dda2cb98 Mon Sep 17 00:00:00 2001 From: Quentin Dufour Date: Mon, 20 Sep 2021 15:00:31 +0200 Subject: Stricter Rust formating rules and build in the CI --- src/igd_actor.rs | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'src/igd_actor.rs') diff --git a/src/igd_actor.rs b/src/igd_actor.rs index 4ff5f53..bb9099e 100644 --- a/src/igd_actor.rs +++ b/src/igd_actor.rs @@ -1,15 +1,16 @@ -use crate::messages; +use std::net::SocketAddrV4; + use anyhow::{Context, Result}; -use igd::aio::*; -use igd::PortMappingProtocol; +use igd::{aio::*, PortMappingProtocol}; use log::*; -use std::net::SocketAddrV4; use tokio::{ select, sync::watch, time::{self, Duration}, }; +use crate::messages; + pub struct IgdActor { last_ports: messages::PublicExposedPorts, rx_ports: watch::Receiver, @@ -40,7 +41,7 @@ impl IgdActor { last_ports: messages::PublicExposedPorts::new(), }; - return Ok(ctx); + return Ok(ctx) } pub async fn listen(&mut self) -> Result<()> { @@ -92,6 +93,6 @@ impl IgdActor { } } - return Ok(()); + return Ok(()) } } -- cgit v1.2.3