Added abstraction of actions inside of file actions.js