fix unfollow dialog

This commit is contained in:
SrGooglo 2023-08-15 18:21:52 +00:00
parent ae41fe06cc
commit 6b13136fa6

View File

@ -65,6 +65,7 @@ export default class Account extends React.Component {
} }
toggleLike = async () => { toggleLike = async () => {
if (this.state.isFollowed) {
const accept = await new Promise((resolve, reject) => { const accept = await new Promise((resolve, reject) => {
antd.Modal.confirm({ antd.Modal.confirm({
title: <Translation> title: <Translation>
@ -91,6 +92,7 @@ export default class Account extends React.Component {
if (!accept) { if (!accept) {
return false return false
} }
}
const result = await FollowsModel.toggleFollow({ const result = await FollowsModel.toggleFollow({
username: this.state.requestedUser, username: this.state.requestedUser,