SyncService: Add distinction main/non-main device
Test / Run tests (push) Successful in 2m26s

This commit is contained in:
2026-08-17 23:29:31 +02:00
parent fc5ad82686
commit eaddf0c3cb
3 changed files with 35 additions and 6 deletions
+2
View File
@@ -50,6 +50,7 @@ namespace Elwig.Helpers {
public string? SyncUrl = null;
public string SyncUsername = "";
public string SyncPassword = "";
public bool SyncMain = false;
public string? SmtpHost = null;
public int? SmtpPort = null;
@@ -86,6 +87,7 @@ namespace Elwig.Helpers {
SyncUrl = config["sync:url"];
SyncUsername = config["sync:username"] ?? "";
SyncPassword = config["sync:password"] ?? "";
SyncMain = TrueValues.Contains(config["sync:main"]?.ToLower());
SmtpHost = config["smtp:host"];
SmtpPort = config["smtp:port"]?.All(char.IsAsciiDigit) == true && config["smtp:port"]?.Length > 0 ? int.Parse(config["smtp:port"]!) : null;