fixes action function to match new design pattern