ChatModel constructor
- String? id,
 - List<
ChatMessageModel> ? messages = const [], - int? unreadMessages,
 - DateTime? lastUsed,
 - ChatMessageModel? lastMessage,
 - bool canBeDeleted = true,
 
Constructs a ChatModel instance.
id: The ID of the chat.
messages: The list of messages in the chat.
unreadMessages: The number of unread messages in the chat.
lastUsed: The timestamp when the chat was last used.
lastMessage: The last message sent in the chat.
canBeDeleted: Indicates whether the chat can be deleted.
Implementation
ChatModel({
  this.id,
  this.messages = const [],
  this.unreadMessages,
  this.lastUsed,
  this.lastMessage,
  this.canBeDeleted = true,
});