We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0142f8f commit ebf070bCopy full SHA for ebf070b
src/cmd/connection.rs
@@ -97,7 +97,7 @@ impl Command for PingCommand {
97
///
98
/// #[ntex::main]
99
/// async fn main() -> Result<(), Box<dyn std::error::Error>> {
100
-/// let redis = RedisConnector::new("127.0.0.1:6379").connect_simple().await?;
+/// let redis = RedisConnector::new("127.0.0.1:6379").connect().await?;
101
102
/// // reset connection
103
/// let response = redis.exec(cmd::Reset()).await?;
src/simple.rs
@@ -26,7 +26,11 @@ impl SimpleClient {
26
U: Command,
27
{
28
self.send(cmd)?;
29
- self.recv::<U>().await.unwrap()
+ loop {
30
+ if let Some(result) = self.recv::<U>().await {
31
+ return result;
32
+ }
33
34
}
35
36
/// Send redis command
0 commit comments