Fix error type
This commit is contained in:
@@ -194,9 +194,8 @@ pub enum GatewayError {
|
||||
#[error("wireguard not set")]
|
||||
WireguardNotSet,
|
||||
|
||||
#[cfg(all(feature = "wireguard", target_os = "linux"))]
|
||||
#[error("failed to catch an interrupt: {source}")]
|
||||
StdError {
|
||||
#[error("failed to start authenticator: {source}")]
|
||||
AuthenticatorStartError {
|
||||
source: Box<dyn std::error::Error + Send + Sync>,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -563,7 +563,7 @@ impl<St> Gateway<St> {
|
||||
Some(
|
||||
self.start_authenticator(shutdown.fork("wireguard"))
|
||||
.await
|
||||
.map_err(|source| GatewayError::StdError { source })?,
|
||||
.map_err(|source| GatewayError::AuthenticatorStartError { source })?,
|
||||
)
|
||||
} else {
|
||||
None
|
||||
|
||||
Reference in New Issue
Block a user