From d379223517897c0da7e27110925fa07916db67b3 Mon Sep 17 00:00:00 2001 From: Shuhrat Tultaganov Date: Sat, 31 Dec 2022 01:47:29 +0300 Subject: [PATCH] add context --- build/postgres/Dockerfile | 2 +- internal/bd/bd.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build/postgres/Dockerfile b/build/postgres/Dockerfile index ae88ae0..84f6652 100644 --- a/build/postgres/Dockerfile +++ b/build/postgres/Dockerfile @@ -1,3 +1,3 @@ -from postgres +FROM postgres ADD ./docker-compose_test_db_init.sql /docker-entrypoint-initdb.d/ \ No newline at end of file diff --git a/internal/bd/bd.go b/internal/bd/bd.go index 56a729a..34c0ddb 100644 --- a/internal/bd/bd.go +++ b/internal/bd/bd.go @@ -32,7 +32,7 @@ func (b *Bd) Open() error { } func (b *Bd) Close() { - b.db.Close() + b.db.Close(context.Background()) } func (b *Bd) Films() *Filmsrepo {