We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e8c1bd3 commit b504e7fCopy full SHA for b504e7f
main.go
@@ -70,13 +70,12 @@ type discordEmbedField struct {
70
71
const defaultListenAddress = "127.0.0.1:9094"
72
73
-func main() {
74
- envWhURL := os.Getenv("DISCORD_WEBHOOK")
75
- whURL := flag.String("webhook.url", envWhURL, "Discord WebHook URL.")
76
-
77
- envListenAddress := os.Getenv("LISTEN_ADDRESS")
78
- listenAddress := flag.String("listen.address", envListenAddress, "Address:Port to listen on.")
+var (
+ whURL = flag.String("webhook.url", os.Getenv("DISCORD_WEBHOOK"), "Discord WebHook URL.")
+ listenAddress = flag.String("listen.address", os.Getenv("LISTEN_ADDRESS"), "Address:Port to listen on.")
+)
79
+func main() {
80
flag.Parse()
81
82
if *whURL == "" {
0 commit comments