diff options
author | Harald Eilertsen <haraldei@anduin.net> | 2019-06-09 19:47:36 +0200 |
---|---|---|
committer | Harald Eilertsen <haraldei@anduin.net> | 2019-06-09 19:47:36 +0200 |
commit | eed9d6ee002e1ad034b3db7057b5a0f8338a736a (patch) | |
tree | 979674a5e0ec0dda1f9c515278ca15aa06e7b7df /src | |
parent | 30e648412c33df5f26a951d5f11b9d602a0da149 (diff) | |
download | rust-zotapi-eed9d6ee002e1ad034b3db7057b5a0f8338a736a.tar.gz rust-zotapi-eed9d6ee002e1ad034b3db7057b5a0f8338a736a.tar.bz2 rust-zotapi-eed9d6ee002e1ad034b3db7057b5a0f8338a736a.zip |
Use rust edition 2018.
Diffstat (limited to 'src')
-rw-r--r-- | src/abconfig.rs | 6 | ||||
-rw-r--r-- | src/abook.rs | 6 | ||||
-rw-r--r-- | src/client.rs | 12 | ||||
-rw-r--r-- | src/item.rs | 6 | ||||
-rw-r--r-- | src/xchan.rs | 6 |
5 files changed, 23 insertions, 13 deletions
diff --git a/src/abconfig.rs b/src/abconfig.rs index 92b8161..78eec4b 100644 --- a/src/abconfig.rs +++ b/src/abconfig.rs @@ -14,8 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. -use client::{self, Client}; -use error::Error; +use crate::{ + client::{self, Client}, + error::Error, +}; pub struct ABConfigFetcher<'a> { client: &'a Client, diff --git a/src/abook.rs b/src/abook.rs index 663446f..f7469e3 100644 --- a/src/abook.rs +++ b/src/abook.rs @@ -14,8 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. -use client::{self, Client}; -use error::Error; +use crate::{ + client::{self, Client}, + error::Error, +}; pub struct AbookFetcher<'a> { client: &'a Client, diff --git a/src/client.rs b/src/client.rs index 3dbca36..138b80c 100644 --- a/src/client.rs +++ b/src/client.rs @@ -14,8 +14,13 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. -use error::Error; -use item::ItemBuilder; +use crate::{ + error::Error, + item::ItemBuilder, + abook::AbookFetcher, + abconfig::ABConfigFetcher, + xchan::XChanFetcher, +}; use reqwest::{ self, header::{ACCEPT, CONTENT_TYPE}, @@ -25,9 +30,6 @@ use serde::Serialize; use serde_urlencoded; use std::collections::BTreeMap; use std::io::Read; -use abook::AbookFetcher; -use abconfig::ABConfigFetcher; -use xchan::XChanFetcher; pub const ZOTAPI_ABOOK_PATH : &str = "/api/z/1.0/abook"; pub const ZOTAPI_ABCONFIG_PATH : &str = "/api/z/1.0/abconfig"; diff --git a/src/item.rs b/src/item.rs index 326e4e8..7ea8c18 100644 --- a/src/item.rs +++ b/src/item.rs @@ -14,8 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. -use client::{self, Client}; -use error::Error; +use crate::{ + client::{self, Client}, + error::Error, +}; use std::collections::BTreeMap; pub struct ItemBuilder<'a> { diff --git a/src/xchan.rs b/src/xchan.rs index d81758a..c67179c 100644 --- a/src/xchan.rs +++ b/src/xchan.rs @@ -14,8 +14,10 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. -use client::{self, Client}; -use error::Error; +use crate::{ + client::{self, Client}, + error::Error, +}; use serde::{Serialize, Serializer}; enum XChanSelector<'a> { |