CustomMessage.fromPartial constructor
CustomMessage.fromPartial({})
Creates a full custom message from a partial one.
Implementation
factory CustomMessage.fromPartial({
required User author,
int? createdAt,
required String id,
required PartialCustom partialCustom,
String? remoteId,
String? roomId,
bool? showStatus,
Status? status,
int? updatedAt,
bool? isEdited,
bool? isDeleted,
Map<String, String>? reactions,
}) =>
_CustomMessage(
author: author,
createdAt: createdAt,
id: id,
metadata: partialCustom.metadata,
remoteId: remoteId,
repliedMessage: partialCustom.repliedMessage,
roomId: roomId,
showStatus: showStatus,
status: status,
type: MessageType.custom,
updatedAt: updatedAt,
isEdited: isEdited ?? false,
isDeleted: isDeleted ?? false,
reactions: reactions ?? const {},
);