From 69cec5bf7ec0ee2b8934910fa9ef61cc106fd9ff Mon Sep 17 00:00:00 2001 From: Aaron Power Date: Fri, 21 Apr 2017 15:18:11 +0100 Subject: [PATCH] Updated status to handle more nulls --- Cargo.toml | 2 +- src/entities/status.rs | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index c9ac861..92e0a0b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "mammut" -version = "0.3.0" +version = "0.4.0" description = "A wrapper around the Mastodon API." authors = ["Aaron Power "] license = "MIT/Apache-2.0" diff --git a/src/entities/status.rs b/src/entities/status.rs index 12e6406..2a69228 100644 --- a/src/entities/status.rs +++ b/src/entities/status.rs @@ -15,15 +15,15 @@ pub struct Status { pub created_at: DateTime, pub reblogs_count: u64, pub favourites_count: u64, - pub reblogged: bool, - pub favourited: bool, - pub sensitive: bool, + pub reblogged: Option, + pub favourited: Option, + pub sensitive: Option, pub spoiler_text: String, pub visibility: Visibility, pub media_attachments: Vec, pub mentions: Vec, pub tags: Vec, - pub application: Application, + pub application: Option, } #[derive(Debug, Clone, Deserialize)]