aboutsummaryrefslogtreecommitdiffstats
path: root/commands/msg/recall.go
diff options
context:
space:
mode:
Diffstat (limited to 'commands/msg/recall.go')
-rw-r--r--commands/msg/recall.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/commands/msg/recall.go b/commands/msg/recall.go
index ef7e859e..7c9ac193 100644
--- a/commands/msg/recall.go
+++ b/commands/msg/recall.go
@@ -107,9 +107,10 @@ func (Recall) Execute(aerc *widgets.Aerc, args []string) error {
part *models.BodyStructure
)
if len(msgInfo.BodyStructure.Parts) != 0 {
- part, path = findPlaintext(msgInfo.BodyStructure, path)
+ path = findPlaintext(msgInfo.BodyStructure, path)
}
- if part == nil {
+ part, err = msgInfo.BodyStructure.PartAtIndex(path)
+ if part == nil || err != nil {
part = msgInfo.BodyStructure
path = []int{1}
}