Fixes the ORM locking issues by ensuring every db.Query closes its returned Stmt.