Page MenuHomePhabricator

D9424.id31802.diff
No OneTemporary

D9424.id31802.diff

diff --git a/lib/actions/user-actions.js b/lib/actions/user-actions.js
--- a/lib/actions/user-actions.js
+++ b/lib/actions/user-actions.js
@@ -90,12 +90,9 @@
const deleteAccount =
(
callServerEndpoint: CallServerEndpoint,
- ): ((
- password: ?string,
- preRequestUserState: PreRequestUserState,
- ) => Promise<LogOutResult>) =>
- async (password, preRequestUserState) => {
- const response = await callServerEndpoint('delete_account', { password });
+ ): ((preRequestUserState: PreRequestUserState) => Promise<LogOutResult>) =>
+ async preRequestUserState => {
+ const response = await callServerEndpoint('delete_account');
return { currentUserInfo: response.currentUserInfo, preRequestUserState };
};
diff --git a/native/profile/delete-account.react.js b/native/profile/delete-account.react.js
--- a/native/profile/delete-account.react.js
+++ b/native/profile/delete-account.react.js
@@ -46,7 +46,6 @@
+dispatchActionPromise: DispatchActionPromise,
// async functions that hit server APIs
+deleteAccount: (
- password: ?string,
preRequestUserState: PreRequestUserState,
) => Promise<LogOutResult>,
};
@@ -158,7 +157,6 @@
try {
await deleteNativeCredentialsFor();
const result = await this.props.deleteAccount(
- this.state.password,
this.props.preRequestUserState,
);
return result;
diff --git a/web/settings/account-delete-modal.react.js b/web/settings/account-delete-modal.react.js
--- a/web/settings/account-delete-modal.react.js
+++ b/web/settings/account-delete-modal.react.js
@@ -32,7 +32,6 @@
+inputDisabled: boolean,
+dispatchActionPromise: DispatchActionPromise,
+deleteAccount: (
- password: ?string,
preRequestUserState: PreRequestUserState,
) => Promise<LogOutResult>,
+popModal: () => void,
@@ -151,7 +150,6 @@
async deleteAction() {
try {
const response = await this.props.deleteAccount(
- this.state.currentPassword,
this.props.preRequestUserState,
);
this.props.popModal();

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 23, 1:26 AM (17 h, 47 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2555216
Default Alt Text
D9424.id31802.diff (2 KB)

Event Timeline