diff options
author | Laria Carolin Chabowski <laria@laria.me> | 2017-10-01 01:07:05 +0200 |
---|---|---|
committer | Laria Carolin Chabowski <laria@laria.me> | 2017-10-03 15:01:38 +0200 |
commit | 7f0771d0a9caf2d3294bfced9e66fac03334d9ba (patch) | |
tree | 37f07c087e36b025503ffbae3a07eebcc3acc649 /storage/registry | |
parent | c04bbf9c82f216891ba44b8b5b621b8020963086 (diff) | |
download | petrific-7f0771d0a9caf2d3294bfced9e66fac03334d9ba.tar.gz petrific-7f0771d0a9caf2d3294bfced9e66fac03334d9ba.tar.bz2 petrific-7f0771d0a9caf2d3294bfced9e66fac03334d9ba.zip |
Redo storage config
Diffstat (limited to 'storage/registry')
-rw-r--r-- | storage/registry/registry.go | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/storage/registry/registry.go b/storage/registry/registry.go index ad66c6a..f792946 100644 --- a/storage/registry/registry.go +++ b/storage/registry/registry.go @@ -35,13 +35,9 @@ func (e storageConfErr) Error() string { } func loadStorage(conf config.Config, storageName string) (storage.Storage, error) { - storageOptions, ok := conf.Storage[storageName] - if !ok { - return nil, notFoundErr - } + method, err := conf.GetStorageMethod(storageName) - var method string - if err := storageOptions.Get("method", &method); err != nil { + if err != nil { return nil, err } |