get_items has an query ambiguity with respect to revision=None. None has a special semantic in get_items as a wildcard, so if we query with 'None' then we'll get back both draft and non-draft items.

This commit is contained in:
Chris Dodge
2013-04-11 22:10:30 -04:00
parent e0bc823365
commit 8fd8574357

View File

@@ -203,7 +203,9 @@ def location_to_query(location, wildcard=True):
if wildcard:
for key, value in query.items():
if value is None:
# don't allow wildcards on revision, since public is set as None, so
# its ambiguous between None as a real value versus None=wildcard
if value is None and key != 'revision':
del query[key]
return query