Skip to content

Commit

Permalink
Move check for current transaction
Browse files Browse the repository at this point in the history
  • Loading branch information
d-frey committed Dec 12, 2023
1 parent 65af54a commit f25b9e2
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 0 additions & 1 deletion include/tao/pq/transaction.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ namespace tao::pq
template< typename... As >
void send( const internal::zsv statement, As&&... as )
{
check_current_transaction();
if constexpr( sizeof...( As ) == 0 ) {
send_params( statement, 0, nullptr, nullptr, nullptr, nullptr );
}
Expand Down
1 change: 1 addition & 0 deletions src/lib/pq/transaction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ namespace tao::pq
const int lengths[],
const int formats[] )
{
check_current_transaction();
m_connection->send_params( statement, n_params, types, values, lengths, formats );
}

Expand Down

0 comments on commit f25b9e2

Please sign in to comment.