aboutsummaryrefslogtreecommitdiffstats
path: root/todolist/parser.go
diff options
context:
space:
mode:
authorGrant Ammons <gammons@gmail.com>2017-03-07 08:28:23 -0500
committerGrant Ammons <gammons@gmail.com>2017-03-07 08:28:23 -0500
commit7b09ad91438e19ba32795fcda908f02fe1b7646f (patch)
treedfd0d42f1ce57f605c246fcaed23138c55981e49 /todolist/parser.go
parent34931b46ed9ebb06e9555d6e62c98c70dc460d59 (diff)
Fix spacing bug when adding todos
All new todos would have a space in them. This fixes that.
Diffstat (limited to 'todolist/parser.go')
-rw-r--r--todolist/parser.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/todolist/parser.go b/todolist/parser.go
index 24a4016..72f6d67 100644
--- a/todolist/parser.go
+++ b/todolist/parser.go
@@ -12,7 +12,7 @@ import (
type Parser struct{}
func (p *Parser) ParseNewTodo(input string) *Todo {
- r, _ := regexp.Compile(`^(add|a)(\\ |)`)
+ r, _ := regexp.Compile(`^(add|a)(\\ |) `)
input = r.ReplaceAllString(input, "")
if input == "" {
return nil