mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-06 05:49:30 +01:00
16 lines
288 B
Rust
16 lines
288 B
Rust
tonic::include_proto!("cln");
|
|
|
|
use cln_rpc::primitives::Amount as JAmount;
|
|
|
|
impl From<JAmount> for Amount {
|
|
fn from(a: JAmount) -> Self {
|
|
Amount { msat: a.msat() }
|
|
}
|
|
}
|
|
|
|
impl From<&Amount> for JAmount {
|
|
fn from(a: &Amount) -> Self {
|
|
JAmount::from_msat(a.msat)
|
|
}
|
|
}
|