Jyxo\SpamFilter::isBlack PHP Method

isBlack() public method

Returns if the given text contains blacklisted words.
public isBlack ( string $text ) : boolean
$text string Checked text
return boolean
    public function isBlack(string $text) : bool
    {
        foreach ($this->blackList as $black) {
            if (false !== strpos($text, $black)) {
                // There is a blacklisted word in the text
                return true;
            }
        }
        return false;
    }