From e59aa43225531d018ed829da4284093c47c60344 Mon Sep 17 00:00:00 2001 From: Shivaram Lingamneni Date: Wed, 19 Feb 2020 00:54:42 -0500 Subject: [PATCH] fix StringToBool (thanks @wrmsr) --- irc/utils/args.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/irc/utils/args.go b/irc/utils/args.go index 98a11ed8..127785e4 100644 --- a/irc/utils/args.go +++ b/irc/utils/args.go @@ -51,9 +51,9 @@ func ArgsToStrings(maxLength int, arguments []string, delim string) []string { func StringToBool(str string) (result bool, err error) { switch strings.ToLower(str) { - case "on", "true", "t", "yes", "y", "disabled": + case "on", "true", "t", "yes", "y", "enabled": result = true - case "off", "false", "f", "no", "n", "enabled": + case "off", "false", "f", "no", "n", "disabled": result = false default: err = ErrInvalidParams