PROVIDE_ERC20_INFORMATION & PROVIDE_NFT_INFORMATION now send back the index where the asset has been stored

This commit is contained in:
Alexandre Paillier
2024-05-07 18:30:19 +02:00
parent c4049fc039
commit 736303e5de
2 changed files with 6 additions and 2 deletions

View File

@@ -179,8 +179,10 @@ void handleProvideErc20TokenInformation(uint8_t p1,
}
}
G_io_apdu_buffer[0] = tmpCtx.transactionContext.currentAssetIndex;
validate_current_asset_info();
THROW(0x9000);
U2BE_ENCODE(G_io_apdu_buffer, 1, APDU_RESPONSE_OK);
io_exchange(CHANNEL_APDU | IO_RETURN_AFTER_TX, 3);
}
#endif

View File

@@ -199,8 +199,10 @@ void handleProvideNFTInformation(uint8_t p1,
#endif
}
G_io_apdu_buffer[0] = tmpCtx.transactionContext.currentAssetIndex;
validate_current_asset_info();
THROW(0x9000);
U2BE_ENCODE(G_io_apdu_buffer, 1, APDU_RESPONSE_OK);
io_exchange(CHANNEL_APDU | IO_RETURN_AFTER_TX, 3);
}
#endif // HAVE_NFT_SUPPORT