// Check whether a domain is blacklisted in a particular channel func checkblacklist(url string, channel string) bool { domain := domainRe.FindStringSubmatch(url)[1] if utils.Contains(core.Config.Channelsettings["global"].Blacklist, domain) { return true } settings, has := core.Config.Channelsettings[channel] return has && utils.Contains(settings.Blacklist, domain) }
func CheckAdmin(nick string) bool { if utils.Contains(core.Config.Admins, nick) { fmt.Println(nick, "verified as admin") return IsAuthenticated(nick) } return false }
func verify_channel(channel string) bool { return channel[0] == '#' && !utils.Contains(blacklist, channel) }