Skip to content

Commit c65112c

Browse files
authored
fix: subject was not parsing from env or config (#11)
1 parent 0420cf3 commit c65112c

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

main.go

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -107,10 +107,15 @@ func main() {
107107
return nil
108108
}
109109

110-
option := models.Option{
111-
Title: &subject,
112-
Subject: &subject,
113-
Priority: &priority,
110+
option := models.Option{}
111+
112+
if ctx.IsSet("subject") {
113+
option.Title = &subject
114+
option.Subject = &subject
115+
}
116+
117+
if ctx.IsSet("priority") {
118+
option.Priority = &priority
114119
}
115120

116121
if len(threadId) > 0 {

0 commit comments

Comments
 (0)