type property
String?
type
The attachment type based on the URL resource. This can be: audio, image or video
Implementation
String? get type {
// If the attachment contains titleLink but is not of type giphy, we
// consider it as a urlPreview.
if (_type != AttachmentType.giphy && titleLink != null) {
return AttachmentType.urlPreview;
}
return _type;
}