8a7e9f83fa
Signed-off-by: Steven Kriegler <sk.bunsenbrenner@gmail.com>
23 lines
315 B
Go
23 lines
315 B
Go
package actions
|
|
|
|
import "strings"
|
|
|
|
type BotAction string
|
|
|
|
const (
|
|
ActionReview BotAction = "/sq-bot review"
|
|
ActionPrefix string = "/sq-bot"
|
|
)
|
|
|
|
func IsValidBotComment(c string) bool {
|
|
if !strings.HasPrefix(c, ActionPrefix) {
|
|
return false
|
|
}
|
|
|
|
if c != string(ActionReview) {
|
|
return false
|
|
}
|
|
|
|
return true
|
|
}
|