From 2fa75902715d36b7a7f202fe5ef4051eea8f15af Mon Sep 17 00:00:00 2001 From: Julia Lange Date: Tue, 17 Jun 2025 14:38:23 -0700 Subject: [PATCH] Atproto, add extraction of values from StrongRef --- atproto/src/types.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/atproto/src/types.rs b/atproto/src/types.rs index 70241b8..26ee60d 100644 --- a/atproto/src/types.rs +++ b/atproto/src/types.rs @@ -73,6 +73,11 @@ impl StrongRef { pub fn get_content(&self) -> &T { &self.content } + + pub fn extract_content(self) -> (T, Cid) { + (self.content, self.cid) + } + pub fn get_cid(&self) -> &Cid { &self.cid }