diff --git a/email.go b/email.go index 53409c0..2a257e2 100644 --- a/email.go +++ b/email.go @@ -26,11 +26,7 @@ func (m Model) sendEmailCmd() tea.Cmd { return func() tea.Msg { attachments := make([]string, len(m.Attachments.Items())) for i, a := range m.Attachments.Items() { - at, ok := a.(attachment) - if !ok { - continue - } - attachments[i] = string(at) + attachments[i] = a.FilterValue() } err := sendEmail(strings.Split(m.To.Value(), TO_SEPARATOR), m.From.Value(), m.Subject.Value(), m.Body.Value(), attachments) if err != nil {