forked from TrueCloudLab/frostfs-node
[#1132] *: Use path/filepath
package when working with files
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
0decb95591
commit
674f520da7
20 changed files with 73 additions and 77 deletions
|
@ -2,7 +2,7 @@ package meta
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"path"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/nspcc-dev/neofs-node/pkg/util"
|
||||
"go.etcd.io/bbolt"
|
||||
|
@ -11,7 +11,7 @@ import (
|
|||
|
||||
// Open boltDB instance for metabase.
|
||||
func (db *DB) Open() error {
|
||||
err := util.MkdirAllX(path.Dir(db.info.Path), db.info.Permission)
|
||||
err := util.MkdirAllX(filepath.Dir(db.info.Path), db.info.Permission)
|
||||
if err != nil {
|
||||
return fmt.Errorf("can't create dir %s for metabase: %w", db.info.Path, err)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue