Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,13 @@ public RsData<PostLikedResponse> likePost(@PathVariable Long post_id) {

@Operation(summary = "게시글 싫어요")
@PostMapping("/{post_id}/disliked")
public RsData<PostLikedResponse> disLikePost(@PathVariable Long post_id) {
public RsData<PostDisLikedResponse> disLikePost(@PathVariable Long post_id) {
postLikeService.disLikePost(post_id);

int likeCount = postLikeService.getDisLikeCount(post_id);
PostLikedResponse postLikedResponse = new PostLikedResponse(likeCount);
PostDisLikedResponse postdisLikedResponse = new PostDisLikedResponse(likeCount);

return new RsData<>("200", "게시글 싫어요 성공", postLikedResponse);
return new RsData<>("200", "게시글 싫어요 성공", postdisLikedResponse);
}


Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.back.domain.post.post.dto;

public record PostDisLikedResponse(int disLikeCount) {
}