4
0
mirror of https://github.com/cwinfo/matterbridge.git synced 2025-07-05 21:54:06 +00:00

Update vendor lrstanley/girc

This commit is contained in:
Wim
2018-05-09 22:48:39 +02:00
parent 529b188164
commit 521a7ed7b0
10 changed files with 203 additions and 846 deletions

View File

@ -136,7 +136,7 @@ func TrimFmt(text string) string {
return text
}
// This is really the only fastest way of doing this (marginably better than
// This is really the only fastest way of doing this (marginally better than
// actually trying to parse it manually.)
var reStripColor = regexp.MustCompile(`\x03([019]?[0-9](,[019]?[0-9])?)?`)
@ -154,7 +154,7 @@ func StripRaw(text string) string {
return text
}
// IsValidChannel validates if channel is an RFC complaint channel or not.
// IsValidChannel validates if channel is an RFC compliant channel or not.
//
// NOTE: If you are using this to validate a channel that contains a channel
// ID, (!<channelid>NAME), this only supports the standard 5 character length.
@ -271,7 +271,7 @@ func IsValidUser(name string) bool {
}
// Check to see if the first index is alphanumeric.
if (name[0] < 'A' || name[0] > 'J') && (name[0] < 'a' || name[0] > 'z') && (name[0] < '0' || name[0] > '9') {
if (name[0] < 'A' || name[0] > 'Z') && (name[0] < 'a' || name[0] > 'z') && (name[0] < '0' || name[0] > '9') {
return false
}