Unverified Commit 95d088f5 authored by Paul Kaplan's avatar Paul Kaplan Committed by GitHub

Merge pull request #2191 from paulkaplan/fix-delete-comment

Fix comment delete endpoint
parents 9106a143 cef36682
...@@ -626,14 +626,11 @@ module.exports.updateProject = (id, jsonData, username, token) => (dispatch => { ...@@ -626,14 +626,11 @@ module.exports.updateProject = (id, jsonData, username, token) => (dispatch => {
module.exports.deleteComment = (projectId, commentId, topLevelCommentId, token) => (dispatch => { module.exports.deleteComment = (projectId, commentId, topLevelCommentId, token) => (dispatch => {
/* TODO fetching/fetched/error states updates for comment deleting */ /* TODO fetching/fetched/error states updates for comment deleting */
api({ api({
uri: `/proxy/comments/project/${projectId}`, uri: `/proxy/comments/project/${projectId}/comment/${commentId}`,
authentication: token, authentication: token,
withCredentials: true, withCredentials: true,
method: 'DELETE', method: 'DELETE',
useCsrf: true, useCsrf: true
json: {
id: commentId
}
}, (err, body, res) => { }, (err, body, res) => {
if (err || res.statusCode !== 200) { if (err || res.statusCode !== 200) {
log.error(err || res.body); log.error(err || res.body);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment