We do this for `Payment*` in `lightning-types` and its needed for
the `hex_conservaitve` `impl_fmt_traits` macro which we'll use in
the next commit.
chan
} else {
let update_actions = peer_state.monitor_update_blocked_actions
- .remove(&channel_id).unwrap_or(Vec::new());
+ .remove(channel_id).unwrap_or(Vec::new());
mem::drop(peer_state_lock);
mem::drop(per_peer_state);
self.handle_monitor_update_completion_actions(update_actions);
HashEngine as _,
sha256::Hash as Sha256,
};
+use core::borrow::Borrow;
use core::fmt;
use core::ops::Deref;
}
}
+impl Borrow<[u8]> for ChannelId {
+ fn borrow(&self) -> &[u8] {
+ &self.0[..]
+ }
+}
+
pub use lightning_types::payment::{PaymentHash, PaymentPreimage, PaymentSecret};
#[cfg(test)]