fix guardActions in script