refactor: consolidate lang into constants, rename services to email
- Merge lang package into constants (add IsValidLang, ValidateLang, AllLangs) - Rename internal/services to internal/email for consistency with pdf package - Rename types to avoid redundancy: EmailService→Service, EmailConfig→Config - Update all imports and references across codebase - Delete internal/lang directory (functions moved to constants)
This commit is contained in:
@@ -56,12 +56,12 @@ func Load() *Config {
|
||||
WriteTimeout: getEnvAsInt("WRITE_TIMEOUT", 15),
|
||||
},
|
||||
Template: TemplateConfig{
|
||||
Dir: getEnv("TEMPLATE_DIR", "templates"),
|
||||
PartialsDir: getEnv("PARTIALS_DIR", "templates/partials"),
|
||||
Dir: getEnv("TEMPLATE_DIR", c.DirTemplates),
|
||||
PartialsDir: getEnv("PARTIALS_DIR", c.DirPartials),
|
||||
HotReload: getEnvAsBool("TEMPLATE_HOT_RELOAD", isDevelopment()),
|
||||
},
|
||||
Data: DataConfig{
|
||||
Dir: getEnv("DATA_DIR", "data"),
|
||||
Dir: getEnv("DATA_DIR", c.DirData),
|
||||
},
|
||||
Email: EmailConfig{
|
||||
SMTPHost: getEnv("SMTP_HOST", "smtp.gmail.com"),
|
||||
|
||||
Reference in New Issue
Block a user