moar db close connections fixes