activity::{Create, Delete, Dislike, Like, Remove, Undo, Update},
context,
link::Mention,
- object::{kind::NoteType, properties::ObjectProperties, Note, Tombstone},
+ object::{kind::NoteType, properties::ObjectProperties, Note},
};
+use activitystreams_new::object::Tombstone;
use actix_web::{body::Body, web::Path, HttpResponse, Result};
use diesel::PgConnection;
use failure::Error;
collection::UnorderedCollection,
context,
endpoint::EndpointProperties,
- object::{properties::ObjectProperties, Tombstone},
+ object::properties::ObjectProperties,
Activity,
Base,
BaseBox,
};
use activitystreams_ext::Ext3;
+use activitystreams_new::object::Tombstone;
use actix_web::{body::Body, web::Path, HttpResponse, Result};
use diesel::PgConnection;
use failure::{Error, _core::fmt::Debug};
use activitystreams::{
activity::Follow,
actor::{properties::ApActorProperties, Group, Person},
- object::{Page, Tombstone},
+ object::Page,
};
use activitystreams_ext::{Ext1, Ext2, Ext3};
+use activitystreams_new::{
+ base::BaseExt,
+ object::{Tombstone, TombstoneExt},
+ primitives::XsdString,
+};
use actix_web::{body::Body, HttpResponse, Result};
use chrono::NaiveDateTime;
use diesel::PgConnection;
) -> Result<Tombstone, Error> {
if deleted {
if let Some(updated) = updated {
- let mut tombstone = Tombstone::default();
- tombstone.object_props.set_id(object_id)?;
- tombstone
- .tombstone_props
- .set_former_type_xsd_string(former_type)?
- .set_deleted(convert_datetime(updated))?;
+ let mut tombstone = Tombstone::new();
+ tombstone.set_id(object_id.parse()?);
+ tombstone.set_former_type(former_type.parse::<XsdString>()?);
+ tombstone.set_deleted(convert_datetime(updated).into());
Ok(tombstone)
} else {
Err(format_err!(
use activitystreams::{
activity::{Create, Delete, Dislike, Like, Remove, Undo, Update},
context,
- object::{kind::PageType, properties::ObjectProperties, AnyImage, Image, Page, Tombstone},
+ object::{kind::PageType, properties::ObjectProperties, AnyImage, Image, Page},
BaseBox,
};
use activitystreams_ext::Ext1;
+use activitystreams_new::object::Tombstone;
use actix_web::{body::Body, web::Path, HttpResponse, Result};
use diesel::PgConnection;
use failure::Error;
use activitystreams::{
activity::{Create, Delete, Undo, Update},
context,
- object::{kind::NoteType, properties::ObjectProperties, Note, Tombstone},
+ object::{kind::NoteType, properties::ObjectProperties, Note},
};
+use activitystreams_new::object::Tombstone;
use actix_web::Result;
use diesel::PgConnection;
use failure::Error;
actor::{properties::ApActorProperties, Person},
context,
endpoint::EndpointProperties,
- object::{properties::ObjectProperties, AnyImage, Image, Tombstone},
+ object::{properties::ObjectProperties, AnyImage, Image},
};
use activitystreams_ext::Ext2;
+use activitystreams_new::object::Tombstone;
use actix_web::{body::Body, web::Path, HttpResponse, Result};
use diesel::PgConnection;
use failure::Error;