attachFile method
Implementation
FileAttachment attachFile(String path, {String? mimeType, String? displayName}) {
final attachment = FileAttachment(path: path, mimeType: mimeType, displayName: displayName, initialStatus: UploadStatus.completed);
attachment.addListener(notifyListeners);
_attachmentUploads.add(attachment);
notifyListeners();
return attachment;
}