diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/client/mod.rs | 1 | ||||
| -rw-r--r-- | src/client/rest/ratelimiting.rs | 6 |
2 files changed, 3 insertions, 4 deletions
diff --git a/src/client/mod.rs b/src/client/mod.rs index 0261833..e9ba20b 100644 --- a/src/client/mod.rs +++ b/src/client/mod.rs @@ -18,6 +18,7 @@ //! [`Client`]: struct.Client.html#examples //! [`Context`]: struct.Context.html //! [Client examples]: struct.Client.html#examples +#![allow(zero_ptr)] pub mod gateway; pub mod rest; diff --git a/src/client/rest/ratelimiting.rs b/src/client/rest/ratelimiting.rs index 2f252ac..8e3cce7 100644 --- a/src/client/rest/ratelimiting.rs +++ b/src/client/rest/ratelimiting.rs @@ -214,12 +214,10 @@ pub fn perform<'a, F>(route: Route, f: F) -> Result<Response> .post_hook(&response) }; - if redo.unwrap_or(false) { - continue; + if !redo.unwrap_or(true) { + return Ok(response); } } - - return Ok(response); } } |