move generic secret errors to shared, fix edgecase in cli flags
Signed-off-by: Christian Richter <crichter@owncloud.com>
This commit is contained in:
@@ -2,11 +2,11 @@ package parser
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
|
||||
"github.com/owncloud/ocis/extensions/thumbnails/pkg/config"
|
||||
"github.com/owncloud/ocis/extensions/thumbnails/pkg/config/defaults"
|
||||
ociscfg "github.com/owncloud/ocis/ocis-pkg/config"
|
||||
"github.com/owncloud/ocis/ocis-pkg/shared"
|
||||
|
||||
"github.com/owncloud/ocis/ocis-pkg/config/envdecode"
|
||||
)
|
||||
@@ -36,7 +36,7 @@ func ParseConfig(cfg *config.Config) error {
|
||||
|
||||
func Validate(cfg *config.Config) error {
|
||||
if cfg.Thumbnail.TransferSecret == "" {
|
||||
return fmt.Errorf("reva transfer secret is not set up properly, bailing out (%s)", cfg.Service.Name)
|
||||
return shared.MissingRevaTransferSecretError(cfg.Service.Name)
|
||||
}
|
||||
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user