impl IntoResource for &Thing (#2482)

This commit is contained in:
Rushmore Mushambi 2023-08-21 14:48:31 +02:00 committed by GitHub
parent d52784f953
commit 76478b37cd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -144,6 +144,12 @@ impl<R> IntoResource<Option<R>> for Thing {
} }
} }
impl<R> IntoResource<Option<R>> for &Thing {
fn into_resource(self) -> Result<Resource> {
Ok(Resource::RecordId(self.clone()))
}
}
impl<R, T, I> IntoResource<Option<R>> for (T, I) impl<R, T, I> IntoResource<Option<R>> for (T, I)
where where
T: Into<String>, T: Into<String>,