Explorar o código

Replace config struct tags

Kailash Nadh %!s(int64=6) %!d(string=hai) anos
pai
achega
089522a2e5
Modificáronse 1 ficheiros con 7 adicións e 7 borrados
  1. 7 7
      main.go

+ 7 - 7
main.go

@@ -25,13 +25,13 @@ import (
 )
 )
 
 
 type constants struct {
 type constants struct {
-	RootURL      string   `mapstructure:"root"`
-	LogoURL      string   `mapstructure:"logo_url"`
-	FaviconURL   string   `mapstructure:"favicon_url"`
-	UploadPath   string   `mapstructure:"upload_path"`
-	UploadURI    string   `mapstructure:"upload_uri"`
-	FromEmail    string   `mapstructure:"from_email"`
-	NotifyEmails []string `mapstructure:"notify_emails"`
+	RootURL      string   `koanf:"root"`
+	LogoURL      string   `koanf:"logo_url"`
+	FaviconURL   string   `koanf:"favicon_url"`
+	UploadPath   string   `koanf:"upload_path"`
+	UploadURI    string   `koanf:"upload_uri"`
+	FromEmail    string   `koanf:"from_email"`
+	NotifyEmails []string `koanf:"notify_emails"`
 }
 }
 
 
 // App contains the "global" components that are
 // App contains the "global" components that are