File tree 2 files changed +4
-2
lines changed
2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -194,9 +194,11 @@ def to_me(self) -> Self:
194
194
self .steps .append (ToMeJudger ())
195
195
return self
196
196
197
- def bind (self , func ):
197
+ def __call__ (self , func ):
198
198
return _bind (self )(func )
199
199
200
+ bind = __call__
201
+
200
202
def and_ (self , other : Union ["Filter" , _SessionFilter ]) -> "Filter" :
201
203
new = Filter ()
202
204
_other = other if isinstance (other , Filter ) else Filter (callback = other )
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ async def _(session: Session):
46
46
return await session .send ("Filter: public message, to me, and content is 'aaa'" )
47
47
48
48
49
- @disp_message . on ( auxiliaries = [ Filter ().public ().to_me ().not_ (lambda sess : str (sess .content ) == "aaa" )] )
49
+ @Filter ().public ().to_me ().not_ (lambda sess : str (sess .content ) == "aaa" )
50
50
async def _ (session : Session ):
51
51
return await session .send ("Filter: public message, to me, but content is not 'aaa'" )
52
52
You can’t perform that action at this time.
0 commit comments