minor code fix in iap.mm