Build events only once per update

This commit is contained in:
Lonami Exo
2018-07-11 11:22:43 +02:00
parent 81f31e09c8
commit 1d0fd6801d
10 changed files with 74 additions and 49 deletions

View File

@@ -25,6 +25,10 @@ class Raw(EventBuilder):
async def resolve(self, client):
pass
def build(self, update):
if not self.types or isinstance(update, self.types):
return update
@staticmethod
def build(update):
return update
def filter(self, event):
if not self.types or isinstance(event, self.types):
return event