From 72f60d5b10b41b7c807524e9746b1e797d8c09ec Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Fri, 17 Jun 2022 00:58:29 +0200 Subject: [PATCH] bin: Fixed boolean encoding bug. --- coe/bin.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/coe/bin.py b/coe/bin.py index e603ff8..b9ee601 100644 --- a/coe/bin.py +++ b/coe/bin.py @@ -89,9 +89,9 @@ class encoder(object): return if datum == None: self.writetag(dst, T_NIL, 0, None) - elif datum == False: + elif datum is False: self.writetag(dst, T_NIL, NIL_FALSE, None) - elif datum == True: + elif datum is True: self.writetag(dst, T_NIL, NIL_TRUE, None) elif isinstance(datum, int): self.writetag(dst, T_INT, 0, None) -- 2.11.0