@cityofzion/bs-neo3 0.14.0 → 0.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/BSNeo3.js +2 -14
- package/package.json +1 -1
package/dist/BSNeo3.js
CHANGED
|
@@ -89,20 +89,8 @@ class BSNeo3 {
|
|
|
89
89
|
}
|
|
90
90
|
decrypt(encryptedKey, password) {
|
|
91
91
|
return __awaiter(this, void 0, void 0, function* () {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
const { NativeModules } = require('react-native');
|
|
95
|
-
BsReactNativeDecrypt = NativeModules.BsReactNativeDecrypt;
|
|
96
|
-
if (!BsReactNativeDecrypt) {
|
|
97
|
-
throw new Error('@CityOfZion/bs-react-native-decrypt is not installed');
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
catch (_a) {
|
|
101
|
-
const key = yield neon_js_1.wallet.decrypt(encryptedKey, password);
|
|
102
|
-
return this.generateAccountFromKey(key);
|
|
103
|
-
}
|
|
104
|
-
const privateKey = yield BsReactNativeDecrypt.decryptNeo3(encryptedKey, password);
|
|
105
|
-
return this.generateAccountFromKey(privateKey);
|
|
92
|
+
const key = yield neon_js_1.wallet.decrypt(encryptedKey, password);
|
|
93
|
+
return this.generateAccountFromKey(key);
|
|
106
94
|
});
|
|
107
95
|
}
|
|
108
96
|
encrypt(key, password) {
|