Documentation
¶
Index ¶
- func ClampInt(num int, min int, max int) int
- func GetStringVal(str string, notSet string) string
- func IsMention(str string) bool
- func IsNSFW(session *discordgo.Session, channelID string) bool
- func IsNumber(str string) bool
- func Matches(str string, str2 string, caseSensitive bool) bool
- func MatchesPrefix(str string, prefix string, caseSensitive bool) bool
- func MentionToID(mention string) string
- func RandomStringElement(array []string) string
- func StringToInt(str string) int
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetStringVal ¶
GetStringVal if string str is not set it returns var notSet, if its set it returns var str
func MatchesPrefix ¶
MatchesPrefix returns whether string has prefix
func MentionToID ¶
MentionToID converts mention <@...> thing to user ID
func RandomStringElement ¶
RandomStringElement Returns random element from string array
func StringToInt ¶
StringToInt converts string to int, if its invalid returns -1
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.