From b50820ecc03f370b2ae68b71b205fb3d650f283f Mon Sep 17 00:00:00 2001 From: Lorenz Leutgeb Date: Thu, 28 Sep 2023 11:16:38 +0200 Subject: [PATCH] config: Default `WireGuard::extra_params` to empty `Vec` Otherwise, omitting `extra_params` in the configuration file will result in a `WireGuard` configuration object of `None`, even though not specifying `extra_params` is sane. --- src/config.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/config.rs b/src/config.rs index facf6cfb..183aa572 100644 --- a/src/config.rs +++ b/src/config.rs @@ -55,6 +55,8 @@ pub struct RosenpassPeer { pub struct WireGuard { pub device: String, pub peer: String, + + #[serde(default)] pub extra_params: Vec, }