Added Filters.all (#464)

Useful filter to use as default value when extending Handler class
This commit is contained in:
Princic-1837592 2020-08-20 16:38:54 +02:00 committed by GitHub
parent cefad3f89a
commit 4df9357b48
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -65,6 +65,9 @@ class Filters:
create = create
all = create(lambda _, m: True, "AllFilter")
"""Filter all messages."""
me = create(lambda _, m: bool(m.from_user and m.from_user.is_self), "MeFilter")
"""Filter messages generated by you yourself."""