feat: add convenience impl From Log
+use ethabi::RawLog;
// Adapted from https://github.com/tomusdrw/rust-web3/blob/master/src/types/log.rs
use crate::types::{Address, Bytes, H256, U256, U64};
use serde::{Deserialize, Serialize};
@@ -68,4 +69,10 @@ impl rlp::Encodable for Log {
}
}
+impl From<Log> for RawLog {
+ fn from(val: Log) -> Self {
+ (val.topics, val.data.to_vec()).into()
+ }
+}
+
// TODO: Implement more common types - or adjust this to work with all Tokenizable items
