2017-05-07 11:53:55 -05:00
|
|
|
package match
|
|
|
|
|
|
|
|
import "strings"
|
|
|
|
|
|
|
|
// Prefix is a simple Matcher, if the word is it's prefix, there is a match
|
|
|
|
// Match returns true if a has the prefix as prefix
|
2017-05-11 12:48:40 -05:00
|
|
|
func Prefix(long, prefix string) bool {
|
|
|
|
return strings.HasPrefix(long, prefix)
|
2017-05-07 11:53:55 -05:00
|
|
|
}
|