check for bogus hashtags

This commit is contained in:
Ted Unangst 2019-09-17 09:53:01 -04:00
parent 2213f0e935
commit bef74481c8
1 changed files with 5 additions and 1 deletions

View File

@ -659,7 +659,11 @@ func xonkxonk(user *WhatAbout, item junk.Junk, origin string) *Honk {
} }
} }
if tt == "Hashtag" { if tt == "Hashtag" {
if len(name) > 1 && name[0] == '#' {
xonk.Onts = append(xonk.Onts, name) xonk.Onts = append(xonk.Onts, name)
} else {
log.Printf("bogus hashtag name: %s", name)
}
} }
} }
xonk.Onts = oneofakind(xonk.Onts) xonk.Onts = oneofakind(xonk.Onts)