Merge branch 'main' into feature/birthday-calendar

This commit is contained in:
Lennart
2025-11-22 18:30:44 +01:00
34 changed files with 649 additions and 241 deletions

View File

@@ -1,6 +1,7 @@
[package]
name = "rustical_store"
version.workspace = true
rust-version.workspace = true
edition.workspace = true
description.workspace = true
repository.workspace = true
@@ -8,15 +9,16 @@ license.workspace = true
publish = false
[dependencies]
anyhow = { workspace = true }
async-trait = { workspace = true }
serde = { workspace = true }
ical = { workspace = true }
chrono = { workspace = true }
regex = { workspace = true }
thiserror = { workspace = true }
tracing = { workspace = true }
chrono-tz = { workspace = true }
anyhow.workspace = true
async-trait.workspace = true
serde.workspace = true
sha2.workspace = true
ical.workspace = true
chrono.workspace = true
regex.workspace = true
thiserror.workspace = true
tracing.workspace = true
chrono-tz.workspace = true
derive_more = { workspace = true, features = ["as_ref"] }
rustical_xml.workspace = true
tokio.workspace = true
@@ -33,7 +35,7 @@ tower-sessions.workspace = true
vtimezones-rs.workspace = true
[dev-dependencies]
rstest = { workspace = true }
rstest_reuse = { workspace = true }
rstest.workspace = true
rstest_reuse.workspace = true
rustical_store_sqlite.workspace = true
tokio.workspace = true

View File

@@ -2,7 +2,7 @@ use crate::synctoken::format_synctoken;
use chrono::NaiveDateTime;
use serde::Serialize;
#[derive(Debug, Clone, Serialize)]
#[derive(Debug, Clone, Serialize, PartialEq, Eq)]
pub struct Addressbook {
pub id: String,
pub principal: String,

View File

@@ -4,7 +4,7 @@ use rustical_ical::CalendarObjectType;
use serde::{Deserialize, Serialize};
use std::str::FromStr;
#[derive(Debug, Default, Clone, Serialize, Deserialize)]
#[derive(Debug, Default, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub struct CalendarMetadata {
// Attributes that may be outsourced
pub displayname: Option<String>,
@@ -13,7 +13,7 @@ pub struct CalendarMetadata {
pub color: Option<String>,
}
#[derive(Debug, Default, Clone, Serialize, Deserialize)]
#[derive(Debug, Default, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub struct Calendar {
// Attributes that may be outsourced
#[serde(flatten)]

View File

@@ -41,6 +41,11 @@ impl Error {
_ => StatusCode::INTERNAL_SERVER_ERROR,
}
}
#[must_use]
pub const fn is_not_found(&self) -> bool {
matches!(self, Self::NotFound)
}
}
impl IntoResponse for Error {