mirror of
https://github.com/astuto/astuto.git
synced 2025-12-16 11:47:56 +01:00
Add button to toggle comment is post update
This commit is contained in:
@@ -5,6 +5,7 @@ import {
|
||||
toggleCommentReply,
|
||||
setCommentReplyBody,
|
||||
} from '../actions/handleCommentReplies';
|
||||
import { toggleCommentIsUpdate } from '../actions/updateComment';
|
||||
import { submitComment } from '../actions/submitComment';
|
||||
|
||||
import { State } from '../reducers/rootReducer';
|
||||
@@ -31,6 +32,15 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
dispatch(setCommentReplyBody(commentId, body));
|
||||
},
|
||||
|
||||
toggleCommentIsPostUpdate(
|
||||
postId: number,
|
||||
commentId: number,
|
||||
currentIsPostUpdate: boolean,
|
||||
authenticityToken: string,
|
||||
) {
|
||||
dispatch(toggleCommentIsUpdate(postId, commentId, currentIsPostUpdate, authenticityToken));
|
||||
},
|
||||
|
||||
submitComment(
|
||||
postId: number,
|
||||
body: string,
|
||||
|
||||
Reference in New Issue
Block a user