summaryrefslogtreecommitdiff
path: root/service/http/config.go
diff options
context:
space:
mode:
Diffstat (limited to 'service/http/config.go')
-rw-r--r--service/http/config.go12
1 files changed, 12 insertions, 0 deletions
diff --git a/service/http/config.go b/service/http/config.go
index 26cede37..b11d807c 100644
--- a/service/http/config.go
+++ b/service/http/config.go
@@ -50,6 +50,18 @@ func (c *Config) Hydrate(cfg service.Config) error {
// Valid validates the configuration.
func (c *Config) Valid() error {
+ if c.Uploads == nil {
+ return errors.New("mailformed uploads config")
+ }
+
+ if c.Workers == nil {
+ return errors.New("mailformed workers config")
+ }
+
+ if c.Workers.Pool == nil {
+ return errors.New("mailformed workers config (pool config is missing)")
+ }
+
if err := c.Workers.Pool.Valid(); err != nil {
return err
}