Skip to content

Commit

Permalink
Merge branch 'bug/266-fee-assets' into 'develop'
Browse files Browse the repository at this point in the history
#266 Fix hard-coded fee for issuing assets in sidechain plugin

See merge request PBSA/peerplays!66
  • Loading branch information
serkixenos committed Feb 10, 2022
2 parents a284f42 + bd08c4c commit 8b611c3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ void sidechain_net_handler::settle_sidechain_transactions() {
if (settle_amount.amount != 0) {
if (sto.object_id.is<son_wallet_deposit_id_type>()) {
asset_issue_operation ai_op;
ai_op.fee = asset(2001000);
ai_op.fee = database.current_fee_schedule().calculate_fee(ai_op);
ai_op.issuer = gpo.parameters.son_account();
ai_op.asset_to_issue = settle_amount;
ai_op.issue_to_account = database.get<son_wallet_deposit_object>(sto.object_id).peerplays_from;
Expand All @@ -598,7 +598,7 @@ void sidechain_net_handler::settle_sidechain_transactions() {

if (sto.object_id.is<son_wallet_withdraw_id_type>()) {
asset_reserve_operation ar_op;
ar_op.fee = asset(2001000);
ar_op.fee = database.current_fee_schedule().calculate_fee(ar_op);
ar_op.payer = gpo.parameters.son_account();
ar_op.amount_to_reserve = settle_amount;
proposal_op.proposed_ops.emplace_back(ar_op);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ bool sidechain_net_handler_hive::process_deposit(const son_wallet_deposit_object
proposal_op.proposed_ops.emplace_back(swdp_op);

asset_issue_operation ai_op;
ai_op.fee = asset(2001000);
ai_op.fee = database.current_fee_schedule().calculate_fee(ai_op);
ai_op.issuer = gpo.parameters.son_account();
ai_op.asset_to_issue = asset_to_issue;
ai_op.issue_to_account = swdo.peerplays_from;
Expand Down

0 comments on commit 8b611c3

Please sign in to comment.