@unicitylabs/sphere-sdk 0.3.4 → 0.3.5
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/core/index.cjs +4 -2
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.js +4 -2
- package/dist/core/index.js.map +1 -1
- package/dist/index.cjs +4 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/core/index.js
CHANGED
|
@@ -9120,7 +9120,9 @@ function decryptTextFormatKey(encryptedKey, password) {
|
|
|
9120
9120
|
const key = deriveLegacyKey(password);
|
|
9121
9121
|
const decrypted = CryptoJS7.AES.decrypt(encryptedKey, key);
|
|
9122
9122
|
const result = decrypted.toString(CryptoJS7.enc.Utf8);
|
|
9123
|
-
|
|
9123
|
+
if (!result) return null;
|
|
9124
|
+
if (!/^[0-9a-fA-F]+$/.test(result)) return null;
|
|
9125
|
+
return result;
|
|
9124
9126
|
} catch {
|
|
9125
9127
|
return null;
|
|
9126
9128
|
}
|
|
@@ -10942,7 +10944,7 @@ var Sphere = class _Sphere {
|
|
|
10942
10944
|
await provider.initialize();
|
|
10943
10945
|
}
|
|
10944
10946
|
await this.reinitializeModulesForNewAddress();
|
|
10945
|
-
if (
|
|
10947
|
+
if (!newNametag) {
|
|
10946
10948
|
await this.syncIdentityWithTransport();
|
|
10947
10949
|
}
|
|
10948
10950
|
if (newNametag) {
|