fix compatibility with ConvertToKeycardAccount after recent changes
This commit is contained in:
parent
eed38fe082
commit
db417cb3a3
|
@ -1307,8 +1307,10 @@ class StatusModule extends ReactContextBaseJavaModule implements LifecycleEventL
|
||||||
@ReactMethod
|
@ReactMethod
|
||||||
public void convertToKeycardAccount(final String keyUID, final String accountData, final String options, final String password, final String newPassword, final Callback callback) throws JSONException {
|
public void convertToKeycardAccount(final String keyUID, final String accountData, final String options, final String password, final String newPassword, final Callback callback) throws JSONException {
|
||||||
final String keyStoreDir = this.getKeyStorePath(keyUID);
|
final String keyStoreDir = this.getKeyStorePath(keyUID);
|
||||||
// Temporary fix for broken status-go compatibilty
|
executeRunnableStatusGoMethod(() -> {
|
||||||
executeRunnableStatusGoMethod(() -> Statusgo.convertToKeycardAccount(accountData, options, password, newPassword), callback);
|
Statusgo.initKeystore(keyStoreDir);
|
||||||
|
return Statusgo.convertToKeycardAccount(accountData, options, password, newPassword);
|
||||||
|
}, callback);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -694,6 +694,7 @@ RCT_EXPORT_METHOD(convertToKeycardAccount:(NSString *)keyUID
|
||||||
NSLog(@"convertToKeycardAccount() method called");
|
NSLog(@"convertToKeycardAccount() method called");
|
||||||
#endif
|
#endif
|
||||||
NSURL *multiaccountKeystoreDir = [self getKeyStoreDir:keyUID];
|
NSURL *multiaccountKeystoreDir = [self getKeyStoreDir:keyUID];
|
||||||
|
StatusgoInitKeystore(multiaccountKeystoreDir.path);
|
||||||
NSString *result = StatusgoConvertToKeycardAccount(accountData, settings, currentPassword, newPassword);
|
NSString *result = StatusgoConvertToKeycardAccount(accountData, settings, currentPassword, newPassword);
|
||||||
callback(@[result]);
|
callback(@[result]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
|
|
||||||
(rf/defn dispatch-event
|
(rf/defn dispatch-event
|
||||||
[_ event]
|
[_ event]
|
||||||
{:dispatch [event]})
|
{:dispatch-n [[event]]})
|
||||||
|
|
||||||
(defn vector->string
|
(defn vector->string
|
||||||
"Converts numbers stored in vector into string,
|
"Converts numbers stored in vector into string,
|
||||||
|
|
|
@ -276,12 +276,11 @@
|
||||||
(common/vector->string (get-in db
|
(common/vector->string (get-in db
|
||||||
[:keycard :pin
|
[:keycard :pin
|
||||||
:current])))]
|
:current])))]
|
||||||
(rf/merge cofx
|
{:keycard/generate-and-load-key
|
||||||
{:keycard/generate-and-load-key
|
{:mnemonic mnemonic
|
||||||
{:mnemonic mnemonic
|
:pin pin'
|
||||||
:pin pin'
|
:key-uid (:key-uid multiaccount)
|
||||||
:key-uid (:key-uid multiaccount)
|
:delete-multiaccount? (get-in db [:keycard :delete-account?])}}))
|
||||||
:delete-multiaccount? (get-in db [:keycard :delete-account?])}})))
|
|
||||||
|
|
||||||
(rf/defn factory-reset-card-toggle
|
(rf/defn factory-reset-card-toggle
|
||||||
{:events [:keycard.onboarding.intro.ui/factory-reset-card-toggle]}
|
{:events [:keycard.onboarding.intro.ui/factory-reset-card-toggle]}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
(rf/defn show-bottom-sheet
|
(rf/defn show-bottom-sheet
|
||||||
[{:keys [db]} {:keys [view options]}]
|
[{:keys [db]} {:keys [view options]}]
|
||||||
{:dispatch [:dismiss-keyboard]
|
{:dispatch-n [[:dismiss-keyboard]]
|
||||||
:show-bottom-sheet-overlay nil
|
:show-bottom-sheet-overlay nil
|
||||||
:db (assoc db
|
:db (assoc db
|
||||||
:bottom-sheet/show? true
|
:bottom-sheet/show? true
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
"_comment": "Instead use: scripts/update-status-go.sh <rev>",
|
"_comment": "Instead use: scripts/update-status-go.sh <rev>",
|
||||||
"owner": "status-im",
|
"owner": "status-im",
|
||||||
"repo": "status-go",
|
"repo": "status-go",
|
||||||
"version": "v0.128.0",
|
"version": "v0.128.1",
|
||||||
"commit-sha1": "82596b2b67f82ae6329ad88e34be6240d08c8ff1",
|
"commit-sha1": "551715f493130f436a1f0c1b42efe84720f7e55c",
|
||||||
"src-sha256": "17n461i2cglvs66rpqxdxpka4k9ld9ds2ha6scdli2nrfg9jb4q3"
|
"src-sha256": "1p546m1qghay1j3yawgiadgcim95ld9qafxs3rarvr4xjppj0qgn"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue