Skip to content
This repository has been archived by the owner on Dec 6, 2023. It is now read-only.

Commit

Permalink
Error message for empty message fixes Issue #71
Browse files Browse the repository at this point in the history
  • Loading branch information
scottleedavis committed May 3, 2019
1 parent 0835ab6 commit 842c0f3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions server/parse.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ func (p *Plugin) ParseRequest(request *ReminderRequest) error {
message = strings.Replace(message, commandSplit[0], "", 1)
message = strings.Trim(message, " \"")

if message == "" {
return errors.New("no message parsed")
}
request.Reminder.Message = message

return nil
Expand Down

0 comments on commit 842c0f3

Please sign in to comment.