Skip to content

Commit

Permalink
Add a duplication of TransactionRecord.get_memos()
Browse files Browse the repository at this point in the history
  • Loading branch information
Quexington committed Oct 30, 2024
1 parent 3da6dc8 commit 72046ae
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions chia/rpc/wallet_request_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ class UserFriendlyTransactionRecord(TransactionRecord):
to_address: str
memos: UserFriendlyMemos # type: ignore[assignment]

def get_memos(self) -> dict[bytes32, list[bytes]]:
return {coin_id: ms for coin_id, ms in self.memos.unfriendly_memos}

def to_transaction_record(self) -> TransactionRecord:
return TransactionRecord.from_json_dict_convenience(self.to_json_dict())

Expand Down

0 comments on commit 72046ae

Please sign in to comment.