fix bug in actionIndex