class Tourmaline::LocaleFilter

Overview

Filters messages not from users with a specific language_code. Keep in mind that not all Users have a language_code.

Options:

Context additions:

Example:

filter = LocaleFilter.new(/en|es/)

Defined in:

tourmaline/filters/locale_filter.cr

Constructors

Instance Method Summary

Instance methods inherited from class Tourmaline::Filter

&(other : Filter | FilterGroup) &, |(other : Filter | FilterGroup) |, exec(client : Client, update : Update) : Bool exec

Constructor Detail

def self.new(locale : String | Regex) #

[View source]

Instance Method Detail

def exec(client : Client, update : Update) : Bool #

[View source]