mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2024-12-02 11:59:07 -05:00
Pass the topLevelCommentId to make sure nested comment deleting works
This commit is contained in:
parent
e29caceb6b
commit
c622d52396
1 changed files with 2 additions and 2 deletions
|
@ -611,7 +611,7 @@ module.exports.updateProject = (id, jsonData, username, token) => (dispatch => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
module.exports.deleteComment = (projectId, commentId, 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}`,
|
||||||
|
@ -627,7 +627,7 @@ module.exports.deleteComment = (projectId, commentId, token) => (dispatch => {
|
||||||
log.error(err || res.body);
|
log.error(err || res.body);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
dispatch(module.exports.setCommentDeleted(commentId));
|
dispatch(module.exports.setCommentDeleted(commentId, topLevelCommentId));
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue