toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    'id': id,
    'postId': postId,
    'ownerId': ownerId,
    'parentCommentId': parentCommentId,
    'text': text,
    'createdAt': createdAt.toIso8601String(),
    'updatedAt': updatedAt?.toIso8601String(),
    'isDeleted': isDeleted,
    'reactionCount': reactionCount,
    'myReaction': myReaction,
  };
}