mirror of
https://github.com/owncloud/ocis
synced 2026-04-26 01:35:25 +02:00
fix configuration validation for extensions' server commands
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
// ParseConfig loads the ocis configuration and
|
||||
// copies applicable parts into the commons part, from
|
||||
// where the extensions can copy it into their own config
|
||||
func ParseConfig(cfg *config.Config) error {
|
||||
func ParseConfig(cfg *config.Config, skipValidate bool) error {
|
||||
_, err := config.BindSourcesToStructs("ocis", cfg)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -29,6 +29,10 @@ func ParseConfig(cfg *config.Config) error {
|
||||
|
||||
EnsureCommons(cfg)
|
||||
|
||||
if skipValidate {
|
||||
return nil
|
||||
}
|
||||
|
||||
return Validate(cfg)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user