cleaned up the code a little in alerts and transaction entity and action