Skip to content

Commit 9c224ae

Browse files
authored
feat: as_bytes to ScriptBuf (MetaMask#59)
1 parent c714ee5 commit 9c224ae

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/types/address.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,10 @@ impl ScriptBuf {
128128
pub fn to_string(&self) -> String {
129129
self.0.to_string()
130130
}
131+
132+
pub fn as_bytes(&self) -> Vec<u8> {
133+
self.0.as_bytes().to_vec()
134+
}
131135
}
132136

133137
impl From<BdkScriptBuf> for ScriptBuf {

0 commit comments

Comments
 (0)