aboutsummaryrefslogtreecommitdiffstats
path: root/commands/comment_add.go
diff options
context:
space:
mode:
Diffstat (limited to 'commands/comment_add.go')
-rw-r--r--commands/comment_add.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/commands/comment_add.go b/commands/comment_add.go
index 5a7cd6a8..d0912844 100644
--- a/commands/comment_add.go
+++ b/commands/comment_add.go
@@ -27,13 +27,13 @@ func runCommentAdd(cmd *cobra.Command, args []string) error {
}
if commentAddMessageFile != "" && commentAddMessage == "" {
- commentAddMessage, err = input.FromFile(commentAddMessageFile)
+ commentAddMessage, err = input.BugCommentFileInput(commentAddMessageFile)
if err != nil {
return err
}
}
- if commentAddMessage == "" {
+ if commentAddMessageFile == "" && commentAddMessage == "" {
commentAddMessage, err = input.BugCommentEditorInput(backend, "")
if err == input.ErrEmptyMessage {
fmt.Println("Empty message, aborting.")