Added actions dir for actions files and fixed some errors.
Refactored and updated code.