[#1437] node: Fix contextcheck linter

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2024-10-21 16:27:28 +03:00
parent 6921a89061
commit 7429553266
Signed by: dstepanov-yadro
GPG key ID: 237AF1A763293BC0
209 changed files with 1068 additions and 1036 deletions

View file

@ -91,15 +91,15 @@ func populate() (err error) {
return fmt.Errorf("couldn't open the metabase: %w", err)
}
defer func() {
if errOnClose := db.Close(); errOnClose != nil {
if errOnClose := db.Close(ctx); errOnClose != nil {
err = errors.Join(
err,
fmt.Errorf("couldn't close the metabase: %w", db.Close()),
fmt.Errorf("couldn't close the metabase: %w", db.Close(ctx)),
)
}
}()
if err = db.Init(); err != nil {
if err = db.Init(ctx); err != nil {
return fmt.Errorf("couldn't init the metabase: %w", err)
}