From 9b485cd16cbda2445dd9840a8869ec25d3ef9f95 Mon Sep 17 00:00:00 2001 From: Ben Wheeler Date: Thu, 4 Apr 2019 15:04:27 -0400 Subject: [PATCH] Revert "Merge pull request #2871 from benjiwheeler/pass-ownerusername-to-comment-replies-endpoint" This reverts commit afe6d6f4a4988509b12a4072d0fc181e74559dab, reversing changes made to c00b4fb1896d9b24eb82bd8fc986adb7c828c266. --- src/redux/preview.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/redux/preview.js b/src/redux/preview.js index 97a7ade52..4b8ca6d66 100644 --- a/src/redux/preview.js +++ b/src/redux/preview.js @@ -481,7 +481,7 @@ module.exports.getTopLevelComments = (id, offset, ownerUsername, isAdmin, token) } dispatch(module.exports.setFetchStatus('comments', module.exports.Status.FETCHED)); dispatch(module.exports.setComments(body)); - dispatch(module.exports.getReplies(id, body.map(comment => comment.id), 0, ownerUsername, isAdmin, token)); + dispatch(module.exports.getReplies(id, body.map(comment => comment.id), 0, isAdmin, token)); // If we loaded a full page of comments, assume there are more to load. // This will be wrong (1 / COMMENT_LIMIT) of the time, but does not require @@ -511,13 +511,13 @@ module.exports.getCommentById = (projectId, commentId, ownerUsername, isAdmin, t if (body.parent_id) { // If the comment is a reply, load the parent - return dispatch(module.exports.getCommentById(projectId, body.parent_id, ownerUsername, isAdmin, token)); + return dispatch(module.exports.getCommentById(projectId, body.parent_id, isAdmin, token)); } // If the comment is not a reply, show it as top level and load replies dispatch(module.exports.setFetchStatus('comments', module.exports.Status.FETCHED)); dispatch(module.exports.setComments([body])); - dispatch(module.exports.getReplies(projectId, [body.id], 0, ownerUsername, isAdmin, token)); + dispatch(module.exports.getReplies(projectId, [body.id], 0, isAdmin, token)); }); });