示例#1
0
func StmtClose(conn Conn, stmt *sqlx.Stmt) error {
	if stmt == nil {
		return nil
	}

	switch conn.(type) {
	case *DB:
		return nil
	default:
		return stmt.Close()
	}
}