@@ -123,7 +123,7 @@ pub struct Account<K> {
123123 account_info : AccountInfo ,
124124}
125125
126- impl < K : AccountKeyChains > Account < K > {
126+ impl < K : AccountKeyChains + Sync > Account < K > {
127127 /// Create a new account by providing a key chain
128128 pub fn new (
129129 chain_config : Arc < ChainConfig > ,
@@ -689,7 +689,7 @@ impl<K: AccountKeyChains> Account<K> {
689689
690690 pub fn process_send_request_and_sign (
691691 & mut self ,
692- db_tx : & mut impl WalletStorageWriteUnlocked ,
692+ db_tx : & mut impl WalletStorageWriteLocked ,
693693 request : SendRequest ,
694694 inputs : SelectedInputs ,
695695 change_addresses : BTreeMap < Currency , Address < Destination > > ,
@@ -711,7 +711,7 @@ impl<K: AccountKeyChains> Account<K> {
711711
712712 fn decommission_stake_pool_impl (
713713 & mut self ,
714- db_tx : & mut impl WalletStorageWriteUnlocked ,
714+ db_tx : & mut impl WalletStorageWriteLocked ,
715715 pool_id : PoolId ,
716716 pool_balance : Amount ,
717717 output_address : Option < Destination > ,
@@ -775,7 +775,7 @@ impl<K: AccountKeyChains> Account<K> {
775775
776776 pub fn decommission_stake_pool (
777777 & mut self ,
778- db_tx : & mut impl WalletStorageWriteUnlocked ,
778+ db_tx : & mut impl WalletStorageWriteLocked ,
779779 pool_id : PoolId ,
780780 pool_balance : Amount ,
781781 output_address : Option < Destination > ,
@@ -792,7 +792,7 @@ impl<K: AccountKeyChains> Account<K> {
792792
793793 pub fn decommission_stake_pool_request (
794794 & mut self ,
795- db_tx : & mut impl WalletStorageWriteUnlocked ,
795+ db_tx : & mut impl WalletStorageWriteLocked ,
796796 pool_id : PoolId ,
797797 pool_balance : Amount ,
798798 output_address : Option < Destination > ,
@@ -943,7 +943,7 @@ impl<K: AccountKeyChains> Account<K> {
943943
944944 pub fn create_htlc_tx (
945945 & mut self ,
946- db_tx : & mut impl WalletStorageWriteUnlocked ,
946+ db_tx : & mut impl WalletStorageWriteLocked ,
947947 output_value : OutputValue ,
948948 htlc : HashedTimelockContract ,
949949 median_time : BlockTimestamp ,
@@ -966,7 +966,7 @@ impl<K: AccountKeyChains> Account<K> {
966966
967967 pub fn create_order_tx (
968968 & mut self ,
969- db_tx : & mut impl WalletStorageWriteUnlocked ,
969+ db_tx : & mut impl WalletStorageWriteLocked ,
970970 ask_value : OutputValue ,
971971 give_value : OutputValue ,
972972 conclude_address : Address < Destination > ,
@@ -992,7 +992,7 @@ impl<K: AccountKeyChains> Account<K> {
992992
993993 pub fn create_conclude_order_tx (
994994 & mut self ,
995- db_tx : & mut impl WalletStorageWriteUnlocked ,
995+ db_tx : & mut impl WalletStorageWriteLocked ,
996996 order_id : OrderId ,
997997 order_info : RpcOrderInfo ,
998998 output_address : Option < Destination > ,
@@ -1062,7 +1062,7 @@ impl<K: AccountKeyChains> Account<K> {
10621062 #[ allow( clippy:: too_many_arguments) ]
10631063 pub fn create_fill_order_tx (
10641064 & mut self ,
1065- db_tx : & mut impl WalletStorageWriteUnlocked ,
1065+ db_tx : & mut impl WalletStorageWriteLocked ,
10661066 order_id : OrderId ,
10671067 order_info : RpcOrderInfo ,
10681068 fill_amount_in_ask_currency : Amount ,
@@ -1151,7 +1151,7 @@ impl<K: AccountKeyChains> Account<K> {
11511151
11521152 pub fn create_freeze_order_tx (
11531153 & mut self ,
1154- db_tx : & mut impl WalletStorageWriteUnlocked ,
1154+ db_tx : & mut impl WalletStorageWriteLocked ,
11551155 order_id : OrderId ,
11561156 order_info : RpcOrderInfo ,
11571157 median_time : BlockTimestamp ,
@@ -1176,7 +1176,7 @@ impl<K: AccountKeyChains> Account<K> {
11761176
11771177 pub fn create_issue_nft_tx (
11781178 & mut self ,
1179- db_tx : & mut impl WalletStorageWriteUnlocked ,
1179+ db_tx : & mut impl WalletStorageWriteLocked ,
11801180 nft_issue_arguments : IssueNftArguments ,
11811181 median_time : BlockTimestamp ,
11821182 fee_rate : CurrentFeeRate ,
@@ -1241,7 +1241,7 @@ impl<K: AccountKeyChains> Account<K> {
12411241
12421242 pub fn mint_tokens (
12431243 & mut self ,
1244- db_tx : & mut impl WalletStorageWriteUnlocked ,
1244+ db_tx : & mut impl WalletStorageWriteLocked ,
12451245 token_info : & UnconfirmedTokenInfo ,
12461246 address : Address < Destination > ,
12471247 amount : Amount ,
@@ -1269,7 +1269,7 @@ impl<K: AccountKeyChains> Account<K> {
12691269
12701270 pub fn unmint_tokens (
12711271 & mut self ,
1272- db_tx : & mut impl WalletStorageWriteUnlocked ,
1272+ db_tx : & mut impl WalletStorageWriteLocked ,
12731273 token_info : & UnconfirmedTokenInfo ,
12741274 amount : Amount ,
12751275 median_time : BlockTimestamp ,
@@ -1296,7 +1296,7 @@ impl<K: AccountKeyChains> Account<K> {
12961296
12971297 pub fn lock_token_supply (
12981298 & mut self ,
1299- db_tx : & mut impl WalletStorageWriteUnlocked ,
1299+ db_tx : & mut impl WalletStorageWriteLocked ,
13001300 token_info : & UnconfirmedTokenInfo ,
13011301 median_time : BlockTimestamp ,
13021302 fee_rate : CurrentFeeRate ,
@@ -1320,7 +1320,7 @@ impl<K: AccountKeyChains> Account<K> {
13201320
13211321 pub fn freeze_token (
13221322 & mut self ,
1323- db_tx : & mut impl WalletStorageWriteUnlocked ,
1323+ db_tx : & mut impl WalletStorageWriteLocked ,
13241324 token_info : & UnconfirmedTokenInfo ,
13251325 is_token_unfreezable : IsTokenUnfreezable ,
13261326 median_time : BlockTimestamp ,
@@ -1347,7 +1347,7 @@ impl<K: AccountKeyChains> Account<K> {
13471347
13481348 pub fn unfreeze_token (
13491349 & mut self ,
1350- db_tx : & mut impl WalletStorageWriteUnlocked ,
1350+ db_tx : & mut impl WalletStorageWriteLocked ,
13511351 token_info : & UnconfirmedTokenInfo ,
13521352 median_time : BlockTimestamp ,
13531353 fee_rate : CurrentFeeRate ,
@@ -1371,7 +1371,7 @@ impl<K: AccountKeyChains> Account<K> {
13711371
13721372 pub fn change_token_authority (
13731373 & mut self ,
1374- db_tx : & mut impl WalletStorageWriteUnlocked ,
1374+ db_tx : & mut impl WalletStorageWriteLocked ,
13751375 token_info : & UnconfirmedTokenInfo ,
13761376 address : Address < Destination > ,
13771377 median_time : BlockTimestamp ,
@@ -1398,7 +1398,7 @@ impl<K: AccountKeyChains> Account<K> {
13981398
13991399 pub fn change_token_metadata_uri (
14001400 & mut self ,
1401- db_tx : & mut impl WalletStorageWriteUnlocked ,
1401+ db_tx : & mut impl WalletStorageWriteLocked ,
14021402 token_info : & UnconfirmedTokenInfo ,
14031403 metadata_uri : Vec < u8 > ,
14041404 median_time : BlockTimestamp ,
@@ -1426,7 +1426,7 @@ impl<K: AccountKeyChains> Account<K> {
14261426 authority : Destination ,
14271427 tx_input : TxInput ,
14281428 outputs : Vec < TxOutput > ,
1429- db_tx : & mut impl WalletStorageWriteUnlocked ,
1429+ db_tx : & mut impl WalletStorageWriteLocked ,
14301430 median_time : BlockTimestamp ,
14311431 fee_rate : CurrentFeeRate ,
14321432 ) -> Result < SendRequest , WalletError > {
@@ -1448,7 +1448,7 @@ impl<K: AccountKeyChains> Account<K> {
14481448
14491449 pub fn create_stake_pool_with_vrf_key (
14501450 & mut self ,
1451- db_tx : & mut impl WalletStorageWriteUnlocked ,
1451+ db_tx : & mut impl WalletStorageWriteLocked ,
14521452 mut stake_pool_arguments : StakePoolCreationArguments ,
14531453 median_time : BlockTimestamp ,
14541454 fee_rate : CurrentFeeRate ,
@@ -1469,7 +1469,7 @@ impl<K: AccountKeyChains> Account<K> {
14691469 fn create_stake_pool_impl (
14701470 & mut self ,
14711471 stake_pool_arguments : StakePoolCreationArguments ,
1472- db_tx : & mut impl WalletStorageWriteUnlocked ,
1472+ db_tx : & mut impl WalletStorageWriteLocked ,
14731473 vrf_public_key : VRFPublicKey ,
14741474 median_time : BlockTimestamp ,
14751475 fee_rate : CurrentFeeRate ,
@@ -2424,7 +2424,7 @@ struct PreselectedInputs {
24242424 total_input_fees : Amount ,
24252425}
24262426
2427- impl < K : AccountKeyChains + VRFAccountKeyChains > Account < K > {
2427+ impl < K : AccountKeyChains + VRFAccountKeyChains + Sync > Account < K > {
24282428 fn get_vrf_public_key (
24292429 & mut self ,
24302430 db_tx : & mut impl WalletStorageWriteLocked ,
@@ -2495,7 +2495,7 @@ impl<K: AccountKeyChains + VRFAccountKeyChains> Account<K> {
24952495
24962496 pub fn create_stake_pool (
24972497 & mut self ,
2498- db_tx : & mut impl WalletStorageWriteUnlocked ,
2498+ db_tx : & mut impl WalletStorageWriteLocked ,
24992499 mut stake_pool_arguments : StakePoolCreationArguments ,
25002500 median_time : BlockTimestamp ,
25012501 fee_rate : CurrentFeeRate ,
0 commit comments