File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change 11//! LightClient function do_propose generates a proposal to send to specified addresses.
22
33use crate :: {
4+ data:: proposal:: ZingoProposal ,
45 lightclient:: LightClient ,
56 wallet:: tx_map_and_maybe_trees:: { TxMapAndMaybeTrees , TxMapAndMaybeTreesTraitError } ,
67} ;
@@ -169,10 +170,8 @@ impl LightClient {
169170 )
170171 . map_err ( DoProposeError :: Proposal ) ?;
171172
172- self . update_latest_proposal ( crate :: data:: proposal:: ZingoProposal :: Transfer (
173- proposal. clone ( ) ,
174- ) )
175- . await ;
173+ self . update_latest_proposal ( ZingoProposal :: Transfer ( proposal. clone ( ) ) )
174+ . await ;
176175 Ok ( proposal)
177176 }
178177
@@ -245,14 +244,12 @@ impl LightClient {
245244 )
246245 . map_err ( DoProposeError :: ShieldProposal ) ?;
247246
248- self . update_latest_proposal ( crate :: data:: proposal:: ZingoProposal :: Shield (
249- proposed_shield. clone ( ) ,
250- ) )
251- . await ;
247+ self . update_latest_proposal ( ZingoProposal :: Shield ( proposed_shield. clone ( ) ) )
248+ . await ;
252249 Ok ( proposed_shield)
253250 }
254251 /// A helper method that standardizes latest_proposal update
255- async fn update_latest_proposal ( & self , proposal : crate :: data :: proposal :: ZingoProposal ) {
252+ async fn update_latest_proposal ( & self , proposal : ZingoProposal ) {
256253 * ( self . latest_proposal . write ( ) . await ) = Some ( proposal. clone ( ) ) ;
257254 }
258255}
You can’t perform that action at this time.
0 commit comments