mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-08-07 05:14:57 -04:00
move config validation into a separate function
This commit is contained in:
64 files changed
+189
-101
No files matched your search
@@ -29,5 +29,13 @@ func ParseConfig(cfg *config.Config) error {
|
||||
|
||||
defaults.Sanitize(cfg)
|
||||
|
||||
return Validate(cfg)
|
||||
}
|
||||
|
||||
func Validate(cfg *config.Config) error {
|
||||
if cfg.TransferSecret == "" {
|
||||
return ftm.Errorf("reva transfer secret is not set up properly, bailing out (%s)", cfg.Service.Name)
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
Reference in new issue
Block a user