Skip to content

Commit a556161

Browse files
committed
Add new id method for UncheckedProposal
The Receiver Struct has a way of getting the short id but the UncheckedProposal does not. This adds a similar id method for getting the short id instead for the session context instead of exposing the whole context.
1 parent 64d411c commit a556161

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

payjoin/src/receive/v2/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,6 +339,9 @@ impl UncheckedProposal {
339339
_ => Err(InternalSessionError::UnexpectedStatusCode(response.status()).into()),
340340
}
341341
}
342+
343+
/// The per-session identifier
344+
pub fn id(&self) -> ShortId { id(&self.context.s) }
342345
}
343346

344347
/// Typestate to validate that the Original PSBT has no receiver-owned inputs.

0 commit comments

Comments
 (0)