workaround for db.connection not raising error