copyWith method
Builds a a copy of a Comment
id
: The id of the comment
shaderId
: The id of the shader
userId
: The user id of user that posted the comment
picture
: The picture of the user who posted the comment
date
: The date the comment was posted
text
: The text of the comment
hidden
: If the current user comment is hidden
Implementation
Comment copyWith(
{String? id,
String? shaderId,
String? userId,
String? picture,
DateTime? date,
String? text,
bool? hidden}) {
return Comment(
id: id ?? this.id,
shaderId: shaderId ?? this.shaderId,
userId: userId ?? this.userId,
picture: picture ?? this.picture,
date: date ?? this.date,
text: text ?? this.text,
hidden: hidden ?? this.hidden);
}