@arbidocs/sdk 0.4.85 → 0.4.86
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/{browser-BOIk_RaR.d.cts → browser-V51dp6kY.d.cts} +4 -5
- package/dist/{browser-BOIk_RaR.d.ts → browser-V51dp6kY.d.ts} +4 -5
- package/dist/browser.cjs +5 -8
- package/dist/browser.cjs.map +1 -1
- package/dist/browser.d.cts +1 -1
- package/dist/browser.d.ts +1 -1
- package/dist/browser.js +6 -9
- package/dist/browser.js.map +1 -1
- package/dist/index.cjs +5 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +6 -9
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -8139,25 +8139,22 @@ var Arbi = class {
|
|
|
8139
8139
|
return result;
|
|
8140
8140
|
},
|
|
8141
8141
|
/**
|
|
8142
|
-
* Change (or, after recovery, set) the master password
|
|
8143
|
-
*
|
|
8144
|
-
*
|
|
8142
|
+
* Change (or, after recovery, set) the master password. Omit `currentPassword` in recovery
|
|
8143
|
+
* mode. One request: the account identity is re-wrapped under the new password and nothing is
|
|
8144
|
+
* re-encrypted, so the session, the workspace keys and the recovery key all stay as they are.
|
|
8145
8145
|
*/
|
|
8146
8146
|
changePassword: async (params) => {
|
|
8147
8147
|
const client$1 = this.requireClient();
|
|
8148
8148
|
const lr2 = this.requireLogin();
|
|
8149
8149
|
const email = client$1.session.getState().userEmail ?? this.userProfile?.email;
|
|
8150
8150
|
if (!email) throw new ArbiError("The account email is unknown; sign in again.");
|
|
8151
|
-
|
|
8152
|
-
{ ...params, email,
|
|
8151
|
+
await client.changePassword(
|
|
8152
|
+
{ ...params, email, identitySecretKey: lr2.signingPrivateKey },
|
|
8153
8153
|
{
|
|
8154
8154
|
fetchClient: client$1.fetch,
|
|
8155
8155
|
deploymentDomain: this.getDeploymentDomain()
|
|
8156
8156
|
}
|
|
8157
8157
|
);
|
|
8158
|
-
this.loginResult = { ...lr2, signingPrivateKey: result.newSigningPrivateKey };
|
|
8159
|
-
this.wrappedKeys.clear();
|
|
8160
|
-
return result;
|
|
8161
8158
|
},
|
|
8162
8159
|
/** Close the account (soft delete) and sign out. Refused while a subscription is active. */
|
|
8163
8160
|
requestDeletion: async () => {
|