Derive Default for Instance

This commit is contained in:
bitfl0wer 2023-09-03 19:59:03 +02:00
parent d0b4c691ba
commit 09df7a8c7b
No known key found for this signature in database
GPG Key ID: 0ACD574FCF5226CF
1 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ use crate::types::types::subconfigs::limits::rates::RateLimits;
use crate::types::{GeneralConfiguration, Limit, LimitType, User, UserSettings}; use crate::types::{GeneralConfiguration, Limit, LimitType, User, UserSettings};
use crate::UrlBundle; use crate::UrlBundle;
#[derive(Debug, Clone)] #[derive(Debug, Clone, Default)]
/// The [`Instance`]; what you will be using to perform all sorts of actions on the Spacebar server. /// The [`Instance`]; what you will be using to perform all sorts of actions on the Spacebar server.
/// If `limits_information` is `None`, then the instance will not be rate limited. /// If `limits_information` is `None`, then the instance will not be rate limited.
pub struct Instance { pub struct Instance {
@ -25,7 +25,7 @@ pub struct Instance {
pub client: Client, pub client: Client,
} }
#[derive(Debug, Clone, Serialize, Deserialize)] #[derive(Debug, Clone, Serialize, Deserialize, Default)]
pub struct LimitsInformation { pub struct LimitsInformation {
pub ratelimits: HashMap<LimitType, Limit>, pub ratelimits: HashMap<LimitType, Limit>,
pub configuration: RateLimits, pub configuration: RateLimits,