aboutsummaryrefslogtreecommitdiffstats
path: root/commands/msgview/open.go
diff options
context:
space:
mode:
Diffstat (limited to 'commands/msgview/open.go')
-rw-r--r--commands/msgview/open.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/commands/msgview/open.go b/commands/msgview/open.go
index bb22026a..13bd4b11 100644
--- a/commands/msgview/open.go
+++ b/commands/msgview/open.go
@@ -1,7 +1,6 @@
package msgview
import (
- "fmt"
"io"
"mime"
"os"
@@ -52,7 +51,7 @@ func (Open) Execute(aerc *widgets.Aerc, args []string) error {
// try to determine the correct extension based on mimetype
if part, err := mv.MessageView().BodyStructure().PartAtIndex(p.Index); err == nil {
- mimeType = fmt.Sprintf("%s/%s", part.MIMEType, part.MIMESubType)
+ mimeType = part.FullMIMEType()
if exts, _ := mime.ExtensionsByType(mimeType); len(exts) > 0 {
extension = exts[0]
}