1
0

Defer DB closing in main.

This commit is contained in:
Alexander Andreev 2023-02-05 21:08:14 +04:00
parent a5e8af44d6
commit 9452194c83
Signed by: Arav
GPG Key ID: 0388CC8FAA51063F

View File

@ -49,6 +49,7 @@ func main() {
}
hand := http.NewHandlers(*captchaExpiry, *databasesPath, *guestbookOwner, *guestbookPageSize)
defer hand.CloseDB()
srv := http.NewHttpServer()
srv.SetNotFoundHandler(hand.NotFound)