mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 12:46:01 -04:00
add __bool__ alias to __nonzero__ methods
Signed-off-by: Adrian Tschira <nota@notafile.com>
This commit is contained in:
parent
154b44c249
commit
f63ff73c7f
3 changed files with 9 additions and 0 deletions
|
@ -92,6 +92,7 @@ class LoggingContext(object):
|
|||
|
||||
def __nonzero__(self):
|
||||
return False
|
||||
__bool__ = __nonzero__ # python3
|
||||
|
||||
sentinel = Sentinel()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue