peerplays-network / peerplays

The Peerplays Blockchain
https://www.peerplays.com
MIT License
34 stars 18 forks source link

[Easy] Implement notifications for Peerplays objects #373

Open nathanielhourt opened 4 years ago

nathanielhourt commented 4 years ago

Bug Description In db_notify.cpp, there is a function, get_relevant_accounts() to get accounts related to any object type in the system. Several peerplays-specific types are not recognized by this function yet, and should be added. This allows the chain to determine which accounts are affected by a modified object and then enables front-ends to notify affected users of the event.

Modern compilers give a warning when processing this code which is helpful in determining which objects still need to be handled:

db_notify.cpp:314:15: warning: 9 enumeration values not handled in switch: 'sport_object_type', 'event_object_type', 'event_group_object_type'...
db_notify.cpp:388:15: warning: 10 enumeration values not handled in switch: 'impl_collateral_bid_object_type', 'impl_asset_dividend_data_object_type', 'impl_total_distributed_dividend_balance_object_type'...

Impacts Describe which portion(s) of Peerplays may be impacted by this bug. Please tick at least one box.

PBSA / Developer tasks