18 Mar
2019
18 Mar
'19
12:08 p.m.
On Tue, Mar 19, 2019 at 12:27:04AM +1300, Greg Ewing
Juancarlo A?ez wrote:
if settings[MY_KEY] is True: ...
If I saw code like this, it would take a really good argument to convince me that it shouldn't be just
if settings[MY_KEY]: ...
Three-way (tri state) checkbox. You have to distinguish False and None if the possible valuse are None, False and True.
-- Greg
Oleg. -- Oleg Broytman https://phdru.name/ phd@phdru.name Programmers don't die, they just GOSUB without RETURN.