From 10200fceb9a9b1c239c41e4219b15d7bf0280b32 Mon Sep 17 00:00:00 2001 From: furtest Date: Thu, 1 Jan 2026 17:30:28 +0100 Subject: [PATCH] config : fallback to port 22 instead of None The configparser fallback option for port was None set it to use 22 instead as None doesn't make sense --- src/unisync/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/unisync/config.py b/src/unisync/config.py index e615c50..89246b3 100644 --- a/src/unisync/config.py +++ b/src/unisync/config.py @@ -16,7 +16,7 @@ class ServerConfig: sshargs: str = "" hostname: str = "" ip: str = "" - port: int | None = 22 + port: int = 22 def __post_init__(self): """ @@ -85,7 +85,7 @@ def load_config(config_path:str) -> Config: config.get(server_section, "sshargs", fallback=""), config.get(server_section, "hostname", fallback=""), config.get(server_section, "ip", fallback=""), - config.getint(server_section, "port", fallback=None) + config.getint(server_section, "port", fallback=22) ) roots_config = RootsConfig( config.get(roots_section, "local"),