Redefined with-tx to accept a database connection as first argument.