updated action code