diff --git a/ui/redux/actions/comments.js b/ui/redux/actions/comments.js index 44947d109..8196ef288 100644 --- a/ui/redux/actions/comments.js +++ b/ui/redux/actions/comments.js @@ -127,7 +127,6 @@ export function doCommentList( type: ACTIONS.COMMENT_LIST_FAILED, data: 'unable to find claim for uri', }); - return; } @@ -139,7 +138,7 @@ export function doCommentList( }); // Adding 'channel_id' and 'channel_name' enables "CreatorSettings > commentsEnabled". - const authorChannelClaim = claim.value_type === 'channel' ? claim : claim.signing_channel; + const creatorChannelClaim = claim.value_type === 'channel' ? claim : claim.signing_channel; return Comments.comment_list({ page, @@ -147,8 +146,8 @@ export function doCommentList( page_size: pageSize, parent_id: parentId || undefined, top_level: !parentId, - channel_id: authorChannelClaim ? authorChannelClaim.claim_id : undefined, - channel_name: authorChannelClaim ? authorChannelClaim.name : undefined, + channel_id: creatorChannelClaim ? creatorChannelClaim.claim_id : undefined, + channel_name: creatorChannelClaim ? creatorChannelClaim.name : undefined, sort_by: sortBy, }) .then((result: CommentListResponse) => { @@ -162,7 +161,7 @@ export function doCommentList( totalFilteredItems: total_filtered_items, totalPages: total_pages, claimId: claimId, - commenterClaimId: authorChannelClaim ? authorChannelClaim.claim_id : undefined, + creatorClaimId: creatorChannelClaim ? creatorChannelClaim.claim_id : undefined, uri: uri, }, }); @@ -175,7 +174,7 @@ export function doCommentList( dispatch({ type: ACTIONS.COMMENT_LIST_COMPLETED, data: { - authorClaimId: authorChannelClaim ? authorChannelClaim.claim_id : undefined, + creatorClaimId: creatorChannelClaim ? creatorChannelClaim.claim_id : undefined, disabled: true, }, }); diff --git a/ui/redux/reducers/comments.js b/ui/redux/reducers/comments.js index d4fd5b926..29a65a885 100644 --- a/ui/redux/reducers/comments.js +++ b/ui/redux/reducers/comments.js @@ -246,7 +246,7 @@ export default handleActions( claimId, uri, disabled, - commenterClaimId, + creatorClaimId, } = action.data; const commentById = Object.assign({}, state.commentById); @@ -262,8 +262,8 @@ export default handleActions( const isLoadingByParentId = Object.assign({}, state.isLoadingByParentId); const settingsByChannelId = Object.assign({}, state.settingsByChannelId); - settingsByChannelId[commenterClaimId] = { - ...(settingsByChannelId[commenterClaimId] || {}), + settingsByChannelId[creatorClaimId] = { + ...(settingsByChannelId[creatorClaimId] || {}), comments_enabled: !disabled, };