Skip to content

Commit be55b0a

Browse files
committed
[tasks] minor fix
1 parent 374f63d commit be55b0a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

internal/server/tasks/dto_comments.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ type CommentResponse struct {
3333
}
3434

3535
// toCommentResponse converts a domain Comment to an API response.
36-
func toCommentResponse(comment *comments.Comment) *CommentResponse {
37-
return &CommentResponse{
36+
func toCommentResponse(comment *comments.Comment) CommentResponse {
37+
return CommentResponse{
3838
ID: comment.ID,
3939
Author: dto.UserBrief{
4040
ID: comment.AuthorID,
@@ -52,7 +52,7 @@ func toCommentResponse(comment *comments.Comment) *CommentResponse {
5252
func toCommentsList(items []comments.Comment) []CommentResponse {
5353
comments := make([]CommentResponse, 0, len(items))
5454
for _, item := range items {
55-
comments = append(comments, *toCommentResponse(&item))
55+
comments = append(comments, toCommentResponse(&item))
5656
}
5757

5858
return comments

0 commit comments

Comments
 (0)