update cap file

This commit is contained in:
Dmitry Novotochinov 2019-01-09 20:01:00 +03:00 committed by Dmitry Novotochinov
parent 6b915dda5a
commit ab6df22059
2 changed files with 3 additions and 2 deletions

View File

@ -23,6 +23,7 @@ import im.status.keycard.io.APDUException;
public class RNStatusKeycardModule extends ReactContextBaseJavaModule implements LifecycleEventListener {
private static final String TAG = "StatusKeycard";
private static final String CAP_FILENAME = "keycard.cap";
private SmartCard smartCard;
private final ReactApplicationContext reactContext;
@ -223,7 +224,7 @@ public class RNStatusKeycardModule extends ReactContextBaseJavaModule implements
new Thread(new Runnable() {
public void run() {
try {
smartCard.installApplet(ctx.getAssets(), "wallet.cap");
smartCard.installApplet(ctx.getAssets(), CAP_FILENAME);
promise.resolve(true);
} catch (IOException | APDUException | NoSuchAlgorithmException | InvalidKeySpecException e) {
Log.d(TAG, e.getMessage());
@ -239,7 +240,7 @@ public class RNStatusKeycardModule extends ReactContextBaseJavaModule implements
new Thread(new Runnable() {
public void run() {
try {
SmartCardSecrets s = smartCard.installAppletAndInitCard(ctx.getAssets(), "wallet.cap");
SmartCardSecrets s = smartCard.installAppletAndInitCard(ctx.getAssets(), CAP_FILENAME);
WritableMap params = Arguments.createMap();
params.putString("pin", s.getPin());