mirror of
https://github.com/lennart-k/rustical.git
synced 2026-01-30 12:58:28 +00:00
Migrate ical-rs to caldata-rs
This commit is contained in:
@@ -4,11 +4,12 @@ use axum::{
|
||||
extract::{Path, State},
|
||||
response::{IntoResponse, Response},
|
||||
};
|
||||
use http::StatusCode;
|
||||
use ical::{
|
||||
parser::{Component, ComponentMut, vcard},
|
||||
property::ContentLine,
|
||||
use caldata::{
|
||||
VcardParser,
|
||||
component::{Component, ComponentMut},
|
||||
parser::ContentLine,
|
||||
};
|
||||
use http::StatusCode;
|
||||
use rustical_store::{Addressbook, AddressbookStore, SubscriptionStore, auth::Principal};
|
||||
use tracing::instrument;
|
||||
|
||||
@@ -23,7 +24,7 @@ pub async fn route_import<AS: AddressbookStore, S: SubscriptionStore>(
|
||||
return Err(Error::Unauthorized);
|
||||
}
|
||||
|
||||
let parser = vcard::VcardParser::from_slice(body.as_bytes());
|
||||
let parser = VcardParser::from_slice(body.as_bytes());
|
||||
|
||||
let mut objects = vec![];
|
||||
for res in parser {
|
||||
|
||||
@@ -2,8 +2,8 @@ use crate::{
|
||||
address_object::AddressObjectPropWrapperName,
|
||||
addressbook::methods::report::addressbook_query::PropFilterElement,
|
||||
};
|
||||
use caldata::parser::ContentLine;
|
||||
use derive_more::{From, Into};
|
||||
use ical::property::ContentLine;
|
||||
use rustical_dav::xml::{PropfindType, TextMatchElement};
|
||||
use rustical_ical::{AddressObject, UtcDateTime};
|
||||
use rustical_xml::{ValueDeserialize, XmlDeserialize, XmlRootTag};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
use super::{Allof, ParamFilterElement};
|
||||
use ical::{parser::Component, property::ContentLine};
|
||||
use caldata::{component::Component, parser::ContentLine};
|
||||
use rustical_dav::xml::TextMatchElement;
|
||||
use rustical_ical::AddressObject;
|
||||
use rustical_xml::XmlDeserialize;
|
||||
|
||||
Reference in New Issue
Block a user