fix an ugly bug in indexing

any numeric values for indexing that evaluate to `False` in Python (e.g.
0, 0.0) have previously been erroneously overwritten with a value of
`None` resulting in an empty DB index entry.