diff --git a/web/app/common/api.js b/web/app/common/api.js index 08542303..bdbc4c13 100644 --- a/web/app/common/api.js +++ b/web/app/common/api.js @@ -79,7 +79,7 @@ export const setVerifyStatus = ({ id }) => fetcher.put({ withCredentials: true, }); -export const unverify = ({ id }) => fetcher.put({ +export const removeVerifyStatus = ({ id }) => fetcher.put({ url: `/admin/verify/${id}?verified=0`, withCredentials: true, }); @@ -121,7 +121,7 @@ export default { pinComment, unpinComment, setVerifyStatus, - unverify, + removeVerifyStatus, remove, blockUser, unblockUser, diff --git a/web/app/components/comment/comment.jsx b/web/app/components/comment/comment.jsx index 7a13264e..1bc0188b 100644 --- a/web/app/components/comment/comment.jsx +++ b/web/app/components/comment/comment.jsx @@ -173,7 +173,7 @@ export default class Comment extends Component { if (confirm('Do you want to unverify this user?')) { this.setState({ isUserVerified: false }); - api.unverify({ id: userId }).then(() => { + api.removeVerifyStatus({ id: userId }).then(() => { api.getComment({ id }).then(comment => store.replaceComment(comment)); }); }