fix: address code review findings

This commit is contained in:
2026-07-19 19:07:20 +03:00
parent a4c426f640
commit c70f46af27
10 changed files with 77 additions and 124 deletions

View File

@@ -84,6 +84,9 @@ func NewApp(ctx context.Context, cfg *config.Config) (*App, error) {
// Close cleans up all application resources in reverse order of initialization.
func (a *App) Close() {
if a.mbClient != nil {
a.mbClient.Close()
}
if a.db != nil {
if err := a.db.Close(); err != nil {
log.Printf("Error closing database: %v", err)