diff --git a/main.go b/main.go index 0f832a2..be5ee6b 100644 --- a/main.go +++ b/main.go @@ -61,9 +61,12 @@ func run(w string) { } log.Info().Str("wallet", w).Msg("Claim successful!") } else { - if string(body) == "error code: 1015" { + switch { + case string(body) == "error code: 1015": log.Info().Str("wallet", w).Msg("Claim already made!") - } else { + case string(body) == "error code: 1020": + log.Warn().Str("wallet", w).Msg("Network is down") + default: log.Error().Str("wallet", w).Msg(string(body)) } }