Fixed parameter wp.getCmd().getType() once the APM only handle with the command type, not the command name.