Add missing name for Filters.update classes (#1632)

This commit is contained in:
Bibo-Joshi 2020-01-26 21:18:29 +01:00 committed by Noam Meltzer
parent 4b5ba15d31
commit 33280a7fe0

View file

@ -987,8 +987,10 @@ officedocument.wordprocessingml.document")``-
class _UpdateType(BaseFilter):
update_filter = True
name = 'Filters.update'
class _Message(BaseFilter):
name = 'Filters.update.message'
update_filter = True
def filter(self, update):
@ -997,6 +999,7 @@ officedocument.wordprocessingml.document")``-
message = _Message()
class _EditedMessage(BaseFilter):
name = 'Filters.update.edited_message'
update_filter = True
def filter(self, update):
@ -1005,6 +1008,7 @@ officedocument.wordprocessingml.document")``-
edited_message = _EditedMessage()
class _Messages(BaseFilter):
name = 'Filters.update.messages'
update_filter = True
def filter(self, update):
@ -1013,6 +1017,7 @@ officedocument.wordprocessingml.document")``-
messages = _Messages()
class _ChannelPost(BaseFilter):
name = 'Filters.update.channel_post'
update_filter = True
def filter(self, update):
@ -1022,6 +1027,7 @@ officedocument.wordprocessingml.document")``-
class _EditedChannelPost(BaseFilter):
update_filter = True
name = 'Filters.update.edited_channel_post'
def filter(self, update):
return update.edited_channel_post is not None
@ -1030,6 +1036,7 @@ officedocument.wordprocessingml.document")``-
class _ChannelPosts(BaseFilter):
update_filter = True
name = 'Filters.update.channel_posts'
def filter(self, update):
return update.channel_post is not None or update.edited_channel_post is not None