@@ -27,8 +27,8 @@ struct get_impacted_account_visitor
27
27
flat_set<account_id_type>& _impacted;
28
28
bool _ignore_custom_op_reqd_auths;
29
29
30
- get_impacted_account_visitor (flat_set<account_id_type>& impact, bool ignore_custom_operation_required_auths)
31
- : _impacted(impact), _ignore_custom_op_reqd_auths(ignore_custom_operation_required_auths)
30
+ get_impacted_account_visitor ( flat_set<account_id_type>& impact, bool ignore_custom_operation_required_auths )
31
+ : _impacted( impact ), _ignore_custom_op_reqd_auths( ignore_custom_operation_required_auths )
32
32
{}
33
33
34
34
using result_type = void ;
@@ -158,10 +158,10 @@ struct get_impacted_account_visitor
158
158
{
159
159
_impacted.insert ( op.fee_payer () ); // fee_paying_account
160
160
vector<authority> other;
161
- for ( const auto & proposed_op : op.proposed_ops )
162
- operation_get_required_authorities (proposed_op.op , _impacted, _impacted, other, _ignore_custom_op_reqd_auths);
163
- for ( auto & o : other)
164
- add_authority_accounts (_impacted, o);
161
+ for ( const auto & proposed_op : op.proposed_ops )
162
+ operation_get_required_authorities ( proposed_op.op , _impacted, _impacted, other, _ignore_custom_op_reqd_auths );
163
+ for ( auto & o : other )
164
+ add_authority_accounts ( _impacted, o );
165
165
}
166
166
void operator ()( const proposal_update_operation& op )
167
167
{
@@ -218,9 +218,9 @@ struct get_impacted_account_visitor
218
218
}
219
219
void operator ()( const custom_operation& op )
220
220
{
221
- _impacted.insert (op.fee_payer ()); // payer
222
- if ( !_ignore_custom_op_reqd_auths)
223
- _impacted.insert (op.required_auths .begin (), op.required_auths .end ());
221
+ _impacted.insert ( op.fee_payer () ); // payer
222
+ if ( !_ignore_custom_op_reqd_auths )
223
+ _impacted.insert ( op.required_auths .begin (), op.required_auths .end () );
224
224
}
225
225
void operator ()( const assert_operation& op )
226
226
{
@@ -290,17 +290,17 @@ struct get_impacted_account_visitor
290
290
}
291
291
};
292
292
293
- void graphene::chain::operation_get_impacted_accounts (const operation& op, flat_set<account_id_type>& result, bool ignore_custom_operation_required_auths) {
294
- get_impacted_account_visitor vtor = get_impacted_account_visitor (result, ignore_custom_operation_required_auths);
295
- op.visit (vtor);
293
+ void graphene::chain::operation_get_impacted_accounts ( const operation& op, flat_set<account_id_type>& result, bool ignore_custom_operation_required_auths ) {
294
+ get_impacted_account_visitor vtor = get_impacted_account_visitor ( result, ignore_custom_operation_required_auths );
295
+ op.visit ( vtor );
296
296
}
297
297
298
- void graphene::chain::transaction_get_impacted_accounts (const transaction& tx, flat_set<account_id_type>& result, bool ignore_custom_operation_required_auths) {
299
- for ( const auto & op : tx.operations )
300
- operation_get_impacted_accounts (op, result, ignore_custom_operation_required_auths);
298
+ void graphene::chain::transaction_get_impacted_accounts ( const transaction& tx, flat_set<account_id_type>& result, bool ignore_custom_operation_required_auths ) {
299
+ for ( const auto & op : tx.operations )
300
+ operation_get_impacted_accounts ( op, result, ignore_custom_operation_required_auths );
301
301
}
302
302
303
- void get_relevant_accounts (const object* obj, flat_set<account_id_type>& accounts, bool ignore_custom_operation_required_auths) {
303
+ void get_relevant_accounts ( const object* obj, flat_set<account_id_type>& accounts, bool ignore_custom_operation_required_auths ) {
304
304
if ( obj->id .space () == protocol_ids )
305
305
{
306
306
switch ( (object_type)obj->id .type () )
@@ -346,14 +346,14 @@ void get_relevant_accounts(const object* obj, flat_set<account_id_type>& account
346
346
} case proposal_object_type:{
347
347
const auto & aobj = dynamic_cast <const proposal_object*>(obj);
348
348
FC_ASSERT ( aobj != nullptr );
349
- transaction_get_impacted_accounts (aobj->proposed_transaction , accounts,
350
- ignore_custom_operation_required_auths);
349
+ transaction_get_impacted_accounts ( aobj->proposed_transaction , accounts,
350
+ ignore_custom_operation_required_auths );
351
351
break ;
352
352
} case operation_history_object_type:{
353
353
const auto & aobj = dynamic_cast <const operation_history_object*>(obj);
354
354
FC_ASSERT ( aobj != nullptr );
355
- operation_get_impacted_accounts (aobj->op , accounts,
356
- ignore_custom_operation_required_auths);
355
+ operation_get_impacted_accounts ( aobj->op , accounts,
356
+ ignore_custom_operation_required_auths );
357
357
break ;
358
358
} case withdraw_permission_object_type:{
359
359
const auto & aobj = dynamic_cast <const withdraw_permission_object*>(obj);
@@ -410,8 +410,8 @@ void get_relevant_accounts(const object* obj, flat_set<account_id_type>& account
410
410
} case impl_transaction_history_object_type:{
411
411
const auto & aobj = dynamic_cast <const transaction_history_object*>(obj);
412
412
FC_ASSERT ( aobj != nullptr );
413
- transaction_get_impacted_accounts (aobj->trx , accounts,
414
- ignore_custom_operation_required_auths);
413
+ transaction_get_impacted_accounts ( aobj->trx , accounts,
414
+ ignore_custom_operation_required_auths );
415
415
break ;
416
416
} case impl_blinded_balance_object_type:{
417
417
const auto & aobj = dynamic_cast <const blinded_balance_object*>(obj);
@@ -517,7 +517,7 @@ void database::notify_changed_objects()
517
517
}
518
518
519
519
if ( removed_ids.size () )
520
- GRAPHENE_TRY_NOTIFY (removed_objects, removed_ids, removed, removed_accounts_impacted)
520
+ GRAPHENE_TRY_NOTIFY ( removed_objects, removed_ids, removed, removed_accounts_impacted )
521
521
}
522
522
}
523
523
} FC_CAPTURE_AND_LOG ( (0 ) ) }
0 commit comments