From 8456b2e1bc727b3d25ce97732777eb3586929c36 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Wed, 23 May 2018 18:53:44 +0100 Subject: [PATCH] Fix substitution --- yggdrasil.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/yggdrasil.go b/yggdrasil.go index fa607698..9f1aa2aa 100644 --- a/yggdrasil.go +++ b/yggdrasil.go @@ -160,14 +160,14 @@ func main() { "AllowedBoxPubs": "AllowedEncryptionPublicKeys", } for from, to := range changes { - if val, ok := dat[from]; ok { - if val == "" { + if _, ok := dat[from]; ok { + if to == "" { if !*normaliseconf { - log.Println("Warning: Deprecated config option", from, " - please remove") + log.Println("Warning: Deprecated config option", from, "- please remove") } } else { if !*normaliseconf { - log.Println("Warning: Deprecated config option", from, " - please rename to", to) + log.Println("Warning: Deprecated config option", from, "- please rename to", to) } if _, ok := dat[to]; !ok { dat[to] = dat[from]