Use with_skip_flags() to handle virtual ops in clear_expired_orders
This commit is contained in:
parent
2ec92c6695
commit
c65fb6b366
1 changed files with 5 additions and 1 deletions
|
|
@ -118,7 +118,10 @@ void database::clear_expired_proposals()
|
||||||
|
|
||||||
void database::clear_expired_orders()
|
void database::clear_expired_orders()
|
||||||
{
|
{
|
||||||
transaction_evaluation_state cancel_context(this, true);
|
with_skip_flags(
|
||||||
|
get_node_properties().skip_flags | skip_authority_check, [&]()
|
||||||
|
{
|
||||||
|
transaction_evaluation_state cancel_context(this);
|
||||||
|
|
||||||
//Cancel expired limit orders
|
//Cancel expired limit orders
|
||||||
auto& limit_index = get_index_type<limit_order_index>().indices().get<by_expiration>();
|
auto& limit_index = get_index_type<limit_order_index>().indices().get<by_expiration>();
|
||||||
|
|
@ -141,6 +144,7 @@ void database::clear_expired_orders()
|
||||||
canceler.order = order.id;
|
canceler.order = order.id;
|
||||||
apply_operation(cancel_context, canceler);
|
apply_operation(cancel_context, canceler);
|
||||||
}
|
}
|
||||||
|
} );
|
||||||
|
|
||||||
//Process expired force settlement orders
|
//Process expired force settlement orders
|
||||||
auto& settlement_index = get_index_type<force_settlement_index>().indices().get<by_expiration>();
|
auto& settlement_index = get_index_type<force_settlement_index>().indices().get<by_expiration>();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue