diff --git a/include/incredis/batch.hpp b/include/incredis/batch.hpp index c6db274..77d7b14 100644 --- a/include/incredis/batch.hpp +++ b/include/incredis/batch.hpp @@ -41,7 +41,7 @@ namespace redis { ConstReplies replies ( void ) const; Replies replies_nonconst ( void ); - bool replies_requested ( void ) const; + bool replies_ready ( void ) const; void throw_if_failed ( void ); template diff --git a/src/batch.cpp b/src/batch.cpp index 131ad8a..6a0ad5f 100644 --- a/src/batch.cpp +++ b/src/batch.cpp @@ -198,12 +198,12 @@ namespace redis { m_async_conn->wakeup_event_thread(); } - bool Batch::replies_requested() const { + bool Batch::replies_ready() const { return static_cast(0 == m_local_data->local_pending_futures); } auto Batch::replies() const -> ConstReplies { - if (not replies_requested()) { + if (not replies_ready()) { if (m_local_data->local_pending_futures > 0) { std::unique_lock u_lock(m_local_data->pending_futures_mutex); m_local_data->no_more_pending_futures.wait(u_lock, [this]() { return m_local_data->local_pending_futures == 0; });