diff options
| author | Zeyla Hellyer <[email protected]> | 2017-11-11 10:05:33 -0800 |
|---|---|---|
| committer | Zeyla Hellyer <[email protected]> | 2017-11-11 10:05:33 -0800 |
| commit | 348d52b50780109a77a5223d2ede8e0b9a490cfd (patch) | |
| tree | 1049f8ab6be8f9b22ec69a3746ae37a90c6f6a62 /src/http | |
| parent | Simplify Error's `Display` impl (diff) | |
| download | serenity-348d52b50780109a77a5223d2ede8e0b9a490cfd.tar.xz serenity-348d52b50780109a77a5223d2ede8e0b9a490cfd.zip | |
Re-order use statements alphabetically
Diffstat (limited to 'src/http')
| -rw-r--r-- | src/http/mod.rs | 14 | ||||
| -rw-r--r-- | src/http/ratelimiting.rs | 2 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/http/mod.rs b/src/http/mod.rs index 239c777..9e8cba4 100644 --- a/src/http/mod.rs +++ b/src/http/mod.rs @@ -30,6 +30,7 @@ mod error; pub use self::error::Error as HttpError; pub use hyper::status::{StatusClass, StatusCode}; +use constants; use hyper::client::{Client as HyperClient, Request, RequestBuilder, Response as HyperResponse}; use hyper::header::ContentType; use hyper::method::Method; @@ -37,6 +38,8 @@ use hyper::mime::{Mime, SubLevel, TopLevel}; use hyper::net::HttpsConnector; use hyper::{header, Error as HyperError, Result as HyperResult, Url}; use hyper_native_tls::NativeTlsClient; +use internal::prelude::*; +use model::*; use multipart::client::Multipart; use parking_lot::Mutex; use self::ratelimiting::Route; @@ -48,9 +51,6 @@ use std::fs::File; use std::io::{ErrorKind as IoErrorKind, Read}; use std::path::{Path, PathBuf}; use std::sync::Arc; -use constants; -use internal::prelude::*; -use model::*; /// An method used for ratelimiting special routes. /// @@ -1055,10 +1055,10 @@ pub fn get_bans(guild_id: u64) -> Result<Vec<Ban>> { } /// Gets all audit logs in a specific guild. -pub fn get_audit_logs(guild_id: u64, - action_type: Option<u8>, - user_id: Option<u64>, - before: Option<u64>, +pub fn get_audit_logs(guild_id: u64, + action_type: Option<u8>, + user_id: Option<u64>, + before: Option<u64>, limit: Option<u8>) -> Result<AuditLogs> { let response = request!( Route::GuildsIdAuditLogs(guild_id), diff --git a/src/http/ratelimiting.rs b/src/http/ratelimiting.rs index 08dc9ee..498dc7a 100644 --- a/src/http/ratelimiting.rs +++ b/src/http/ratelimiting.rs @@ -44,13 +44,13 @@ use chrono::Utc; use hyper::client::{RequestBuilder, Response}; use hyper::header::Headers; use hyper::status::StatusCode; +use internal::prelude::*; use parking_lot::Mutex; use std::collections::HashMap; use std::sync::Arc; use std::time::Duration; use std::{str, thread, i64}; use super::{HttpError, LightMethod}; -use internal::prelude::*; lazy_static! { /// The global mutex is a mutex unlocked and then immediately re-locked |