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) => - async (password, preRequestUserState) => { - const response = await callServerEndpoint('delete_account', { password }); + ): ((preRequestUserState: PreRequestUserState) => Promise) => + 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, }; @@ -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, +popModal: () => void, @@ -151,7 +150,6 @@ async deleteAction() { try { const response = await this.props.deleteAccount( - this.state.currentPassword, this.props.preRequestUserState, ); this.props.popModal();