Handle empty reply

This commit is contained in:
Matt Low 2023-11-18 15:17:18 +00:00
parent 22e0ff4115
commit 681b52a55c
1 changed files with 3 additions and 0 deletions

View File

@ -236,6 +236,9 @@ var replyCmd = &cobra.Command{
} }
messageContents, err := InputFromEditor("# How would you like to reply?\n", "reply.*.md") messageContents, err := InputFromEditor("# How would you like to reply?\n", "reply.*.md")
if messageContents == "" {
Fatal("No reply was provided.\n")
}
userReply := Message{ userReply := Message{
ConversationID: conversation.ID, ConversationID: conversation.ID,