all repos — honk @ 3ecf0a2d4370479bf1465e06cb5673d54b86364a

my fork of honk

don't include leading space in hashtag
Ted Unangst tedu@tedunangst.com
Sat, 15 Jun 2019 18:30:59 -0400
commit

3ecf0a2d4370479bf1465e06cb5673d54b86364a

parent

78eba0bbb4c62f9e0cdd219c050760ae3f0aa54f

1 files changed, 5 insertions(+), 0 deletions(-)

jump to
M fun.gofun.go

@@ -123,6 +123,11 @@ var re_hashes = regexp.MustCompile(`(?:^|\W)#[[:alnum:]]+`)

func ontologies(s string) []string { m := re_hashes.FindAllString(s, -1) + for i, h := range m { + if h[0] != '#' { + m[i] = h[1:] + } + } return m }