#unpin @method -rename

This commit is contained in:
Alex
2018-06-23 23:09:52 +03:00
parent 7b7934e93c
commit 400905c8ff
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -69,7 +69,7 @@ export const pinComment = ({ id, url }) => fetcher.put({
withCredentials: true,
});
export const unpin = ({ id, url }) => fetcher.put({
export const unpinComment = ({ id, url }) => fetcher.put({
url: `/admin/pin/${id}?url=${url}&pin=0`,
withCredentials: true,
});
@@ -119,7 +119,7 @@ export default {
getPreview,
pinComment,
unpin,
unpinComment,
verify,
unverify,
remove,
+1 -1
View File
@@ -149,7 +149,7 @@ export default class Comment extends Component {
if (confirm('Do you want to unpin this comment?')) {
this.setState({ pinned: false });
api.unpin({ id, url }).then(() => {
api.unpinComment({ id, url }).then(() => {
api.getComment({ id }).then(comment => store.replaceComment(comment));
});
}