Преглед изворни кода

doc/testnet/token: specified to wait between the two mint transactions

skoupidi пре 7 месеци
родитељ
комит
fbf8d93849

+ 7 - 3
doc/src/testnet/token.md

@@ -153,6 +153,10 @@ Broadcasting transaction...
 Transaction ID: e9ded45928f2e2dbcb4f8365653220a8e2346987dd8b75fe1ffdc401ce0362c2
 Transaction ID: e9ded45928f2e2dbcb4f8365653220a8e2346987dd8b75fe1ffdc401ce0362c2
 ```
 ```
 
 
+Now the transaction should be published to the network, waiting to be
+included in a block. After the transaction is confirmed, perform the
+next one:
+
 ```shell
 ```shell
 drk> token mint DAWN 20.0 {YOUR_ADDRESS} | broadcast
 drk> token mint DAWN 20.0 {YOUR_ADDRESS} | broadcast
 
 
@@ -164,9 +168,9 @@ Broadcasting transaction...
 Transaction ID: e404241902ba0a8825cf199b3083bff81cd518ca30928ca1267d5e0008f32277
 Transaction ID: e404241902ba0a8825cf199b3083bff81cd518ca30928ca1267d5e0008f32277
 ```
 ```
 
 
-Now the transaction should be published to the network. When the
-transaction is confirmed, your wallet should have your new tokens
-listed when you run:
+The transaction is now published to the network. When the transaction
+is confirmed, your wallet should have your new tokens listed when you
+run:
 
 
 ```shell
 ```shell
 drk> wallet balance
 drk> wallet balance

+ 2 - 2
src/contract/dao/src/entrypoint/exec.rs

@@ -148,8 +148,8 @@ pub(crate) fn dao_exec_process_instruction(
 /// `process_update` function for `Dao::Exec`
 /// `process_update` function for `Dao::Exec`
 pub(crate) fn dao_exec_process_update(cid: ContractId, update: DaoExecUpdate) -> ContractResult {
 pub(crate) fn dao_exec_process_update(cid: ContractId, update: DaoExecUpdate) -> ContractResult {
     // Remove proposal from db
     // Remove proposal from db
-    let proposal_vote_db = wasm::db::db_lookup(cid, DAO_CONTRACT_DB_PROPOSAL_BULLAS)?;
-    wasm::db::db_del(proposal_vote_db, &serialize(&update.proposal_bulla))?;
+    let proposal_db = wasm::db::db_lookup(cid, DAO_CONTRACT_DB_PROPOSAL_BULLAS)?;
+    wasm::db::db_del(proposal_db, &serialize(&update.proposal_bulla))?;
 
 
     Ok(())
     Ok(())
 }
 }

+ 2 - 2
src/contract/dao/src/entrypoint/propose.rs

@@ -227,7 +227,7 @@ pub(crate) fn dao_propose_process_update(
     update: DaoProposeUpdate,
     update: DaoProposeUpdate,
 ) -> ContractResult {
 ) -> ContractResult {
     // Grab all db handles we want to work on
     // Grab all db handles we want to work on
-    let proposal_vote_db = wasm::db::db_lookup(cid, DAO_CONTRACT_DB_PROPOSAL_BULLAS)?;
+    let proposal_db = wasm::db::db_lookup(cid, DAO_CONTRACT_DB_PROPOSAL_BULLAS)?;
 
 
     // Build the proposal metadata
     // Build the proposal metadata
     let proposal_metadata = DaoProposalMetadata {
     let proposal_metadata = DaoProposalMetadata {
@@ -238,7 +238,7 @@ pub(crate) fn dao_propose_process_update(
 
 
     // Set the new proposal in the db
     // Set the new proposal in the db
     wasm::db::db_set(
     wasm::db::db_set(
-        proposal_vote_db,
+        proposal_db,
         &serialize(&update.proposal_bulla),
         &serialize(&update.proposal_bulla),
         &serialize(&proposal_metadata),
         &serialize(&proposal_metadata),
     )?;
     )?;