Fixing issue where 'actions' was nil, + formatting