Used the new passed function for AddAction