View Single Post
Old 07-18-2010, 11:47 AM   #18
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Are there any cases where a datatype comments field can have a len(comments) == 0 and comments != False?

I have a test in the non-custom comments field of:

Code:
if not dest_mi.comments or len(dest_mi.comments) == 0:
I can't recall if I did this, not knowing any better, or if Kovid added it because I didn't. In Python, wouldn't the comments field always be False if its length was zero?
Starson17 is offline   Reply With Quote